//===----------------------------------------------------------------------===//
//
// This source file is part of the Soto for AWS open source project
//
// Copyright (c) 2017-2024 the Soto project authors
// Licensed under Apache License v2.0
//
// See LICENSE.txt for license information
// See CONTRIBUTORS.txt for the list of Soto project authors
//
// SPDX-License-Identifier: Apache-2.0
//
//===----------------------------------------------------------------------===//

// THIS FILE IS AUTOMATICALLY GENERATED by https://github.com/soto-project/soto-codegenerator.
// DO NOT EDIT.

#if canImport(FoundationEssentials)
import FoundationEssentials
#else
import Foundation
#endif
@_spi(SotoInternal) import SotoCore

extension Pipes {
    // MARK: Enums

    public enum AssignPublicIp: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case disabled = "DISABLED"
        case enabled = "ENABLED"
        public var description: String { return self.rawValue }
    }

    public enum BatchJobDependencyType: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case nToN = "N_TO_N"
        case sequential = "SEQUENTIAL"
        public var description: String { return self.rawValue }
    }

    public enum BatchResourceRequirementType: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case gpu = "GPU"
        case memory = "MEMORY"
        case vcpu = "VCPU"
        public var description: String { return self.rawValue }
    }

    public enum DimensionValueType: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case varchar = "VARCHAR"
        public var description: String { return self.rawValue }
    }

    public enum DynamoDBStreamStartPosition: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case latest = "LATEST"
        case trimHorizon = "TRIM_HORIZON"
        public var description: String { return self.rawValue }
    }

    public enum EcsEnvironmentFileType: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case s3 = "s3"
        public var description: String { return self.rawValue }
    }

    public enum EcsResourceRequirementType: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case gpu = "GPU"
        case inferenceAccelerator = "InferenceAccelerator"
        public var description: String { return self.rawValue }
    }

    public enum EpochTimeUnit: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case microseconds = "MICROSECONDS"
        case milliseconds = "MILLISECONDS"
        case nanoseconds = "NANOSECONDS"
        case seconds = "SECONDS"
        public var description: String { return self.rawValue }
    }

    public enum IncludeExecutionDataOption: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case all = "ALL"
        public var description: String { return self.rawValue }
    }

    public enum KinesisStreamStartPosition: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case atTimestamp = "AT_TIMESTAMP"
        case latest = "LATEST"
        case trimHorizon = "TRIM_HORIZON"
        public var description: String { return self.rawValue }
    }

    public enum LaunchType: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case ec2 = "EC2"
        case external = "EXTERNAL"
        case fargate = "FARGATE"
        public var description: String { return self.rawValue }
    }

    public enum LogLevel: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case error = "ERROR"
        case info = "INFO"
        case off = "OFF"
        case trace = "TRACE"
        public var description: String { return self.rawValue }
    }

    public enum MSKStartPosition: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case latest = "LATEST"
        case trimHorizon = "TRIM_HORIZON"
        public var description: String { return self.rawValue }
    }

    public enum MeasureValueType: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case bigint = "BIGINT"
        case boolean = "BOOLEAN"
        case double = "DOUBLE"
        case timestamp = "TIMESTAMP"
        case varchar = "VARCHAR"
        public var description: String { return self.rawValue }
    }

    public enum OnPartialBatchItemFailureStreams: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case automaticBisect = "AUTOMATIC_BISECT"
        public var description: String { return self.rawValue }
    }

    public enum PipeState: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case createFailed = "CREATE_FAILED"
        case createRollbackFailed = "CREATE_ROLLBACK_FAILED"
        case creating = "CREATING"
        case deleteFailed = "DELETE_FAILED"
        case deleteRollbackFailed = "DELETE_ROLLBACK_FAILED"
        case deleting = "DELETING"
        case running = "RUNNING"
        case starting = "STARTING"
        case startFailed = "START_FAILED"
        case stopped = "STOPPED"
        case stopping = "STOPPING"
        case stopFailed = "STOP_FAILED"
        case updateFailed = "UPDATE_FAILED"
        case updateRollbackFailed = "UPDATE_ROLLBACK_FAILED"
        case updating = "UPDATING"
        public var description: String { return self.rawValue }
    }

    public enum PipeTargetInvocationType: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case fireAndForget = "FIRE_AND_FORGET"
        case requestResponse = "REQUEST_RESPONSE"
        public var description: String { return self.rawValue }
    }

    public enum PlacementConstraintType: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case distinctInstance = "distinctInstance"
        case memberOf = "memberOf"
        public var description: String { return self.rawValue }
    }

    public enum PlacementStrategyType: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case binpack = "binpack"
        case random = "random"
        case spread = "spread"
        public var description: String { return self.rawValue }
    }

    public enum PropagateTags: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case taskDefinition = "TASK_DEFINITION"
        public var description: String { return self.rawValue }
    }

    public enum RequestedPipeState: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case running = "RUNNING"
        case stopped = "STOPPED"
        public var description: String { return self.rawValue }
    }

    public enum RequestedPipeStateDescribeResponse: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case deleted = "DELETED"
        case running = "RUNNING"
        case stopped = "STOPPED"
        public var description: String { return self.rawValue }
    }

    public enum S3OutputFormat: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case json = "json"
        case plain = "plain"
        case w3c = "w3c"
        public var description: String { return self.rawValue }
    }

    public enum SelfManagedKafkaStartPosition: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case latest = "LATEST"
        case trimHorizon = "TRIM_HORIZON"
        public var description: String { return self.rawValue }
    }

    public enum TimeFieldType: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case epoch = "EPOCH"
        case timestampFormat = "TIMESTAMP_FORMAT"
        public var description: String { return self.rawValue }
    }

    public enum MSKAccessCredentials: AWSEncodableShape & AWSDecodableShape, Sendable {
        /// The ARN of the Secrets Manager secret.
        case clientCertificateTlsAuth(String)
        /// The ARN of the Secrets Manager secret.
        case saslScram512Auth(String)

        public init(from decoder: Decoder) throws {
            let container = try decoder.container(keyedBy: CodingKeys.self)
            guard container.allKeys.count == 1, let key = container.allKeys.first else {
                let context = DecodingError.Context(
                    codingPath: container.codingPath,
                    debugDescription: "Expected exactly one key, but got \(container.allKeys.count)"
                )
                throw DecodingError.dataCorrupted(context)
            }
            switch key {
            case .clientCertificateTlsAuth:
                let value = try container.decode(String.self, forKey: .clientCertificateTlsAuth)
                self = .clientCertificateTlsAuth(value)
            case .saslScram512Auth:
                let value = try container.decode(String.self, forKey: .saslScram512Auth)
                self = .saslScram512Auth(value)
            }
        }

        public func encode(to encoder: Encoder) throws {
            var container = encoder.container(keyedBy: CodingKeys.self)
            switch self {
            case .clientCertificateTlsAuth(let value):
                try container.encode(value, forKey: .clientCertificateTlsAuth)
            case .saslScram512Auth(let value):
                try container.encode(value, forKey: .saslScram512Auth)
            }
        }

        public func validate(name: String) throws {
            switch self {
            case .clientCertificateTlsAuth(let value):
                try self.validate(value, name: "clientCertificateTlsAuth", parent: name, max: 1600)
                try self.validate(value, name: "clientCertificateTlsAuth", parent: name, min: 1)
                try self.validate(value, name: "clientCertificateTlsAuth", parent: name, pattern: "^(^arn:aws([a-z]|\\-)*:secretsmanager:([a-z]{2,4}((-gov)|(-de)|(-iso([a-z]?)))?-[a-z]+(-\\d{1})?):(\\d{12}):secret:.+)$")
            case .saslScram512Auth(let value):
                try self.validate(value, name: "saslScram512Auth", parent: name, max: 1600)
                try self.validate(value, name: "saslScram512Auth", parent: name, min: 1)
                try self.validate(value, name: "saslScram512Auth", parent: name, pattern: "^(^arn:aws([a-z]|\\-)*:secretsmanager:([a-z]{2,4}((-gov)|(-de)|(-iso([a-z]?)))?-[a-z]+(-\\d{1})?):(\\d{12}):secret:.+)$")
            }
        }

        private enum CodingKeys: String, CodingKey {
            case clientCertificateTlsAuth = "ClientCertificateTlsAuth"
            case saslScram512Auth = "SaslScram512Auth"
        }
    }

    public enum SelfManagedKafkaAccessConfigurationCredentials: AWSEncodableShape & AWSDecodableShape, Sendable {
        /// The ARN of the Secrets Manager secret.
        case basicAuth(String)
        /// The ARN of the Secrets Manager secret.
        case clientCertificateTlsAuth(String)
        /// The ARN of the Secrets Manager secret.
        case saslScram256Auth(String)
        /// The ARN of the Secrets Manager secret.
        case saslScram512Auth(String)

        public init(from decoder: Decoder) throws {
            let container = try decoder.container(keyedBy: CodingKeys.self)
            guard container.allKeys.count == 1, let key = container.allKeys.first else {
                let context = DecodingError.Context(
                    codingPath: container.codingPath,
                    debugDescription: "Expected exactly one key, but got \(container.allKeys.count)"
                )
                throw DecodingError.dataCorrupted(context)
            }
            switch key {
            case .basicAuth:
                let value = try container.decode(String.self, forKey: .basicAuth)
                self = .basicAuth(value)
            case .clientCertificateTlsAuth:
                let value = try container.decode(String.self, forKey: .clientCertificateTlsAuth)
                self = .clientCertificateTlsAuth(value)
            case .saslScram256Auth:
                let value = try container.decode(String.self, forKey: .saslScram256Auth)
                self = .saslScram256Auth(value)
            case .saslScram512Auth:
                let value = try container.decode(String.self, forKey: .saslScram512Auth)
                self = .saslScram512Auth(value)
            }
        }

        public func encode(to encoder: Encoder) throws {
            var container = encoder.container(keyedBy: CodingKeys.self)
            switch self {
            case .basicAuth(let value):
                try container.encode(value, forKey: .basicAuth)
            case .clientCertificateTlsAuth(let value):
                try container.encode(value, forKey: .clientCertificateTlsAuth)
            case .saslScram256Auth(let value):
                try container.encode(value, forKey: .saslScram256Auth)
            case .saslScram512Auth(let value):
                try container.encode(value, forKey: .saslScram512Auth)
            }
        }

        public func validate(name: String) throws {
            switch self {
            case .basicAuth(let value):
                try self.validate(value, name: "basicAuth", parent: name, max: 1600)
                try self.validate(value, name: "basicAuth", parent: name, min: 1)
                try self.validate(value, name: "basicAuth", parent: name, pattern: "^(^arn:aws([a-z]|\\-)*:secretsmanager:([a-z]{2,4}((-gov)|(-de)|(-iso([a-z]?)))?-[a-z]+(-\\d{1})?):(\\d{12}):secret:.+)$")
            case .clientCertificateTlsAuth(let value):
                try self.validate(value, name: "clientCertificateTlsAuth", parent: name, max: 1600)
                try self.validate(value, name: "clientCertificateTlsAuth", parent: name, min: 1)
                try self.validate(value, name: "clientCertificateTlsAuth", parent: name, pattern: "^(^arn:aws([a-z]|\\-)*:secretsmanager:([a-z]{2,4}((-gov)|(-de)|(-iso([a-z]?)))?-[a-z]+(-\\d{1})?):(\\d{12}):secret:.+)$")
            case .saslScram256Auth(let value):
                try self.validate(value, name: "saslScram256Auth", parent: name, max: 1600)
                try self.validate(value, name: "saslScram256Auth", parent: name, min: 1)
                try self.validate(value, name: "saslScram256Auth", parent: name, pattern: "^(^arn:aws([a-z]|\\-)*:secretsmanager:([a-z]{2,4}((-gov)|(-de)|(-iso([a-z]?)))?-[a-z]+(-\\d{1})?):(\\d{12}):secret:.+)$")
            case .saslScram512Auth(let value):
                try self.validate(value, name: "saslScram512Auth", parent: name, max: 1600)
                try self.validate(value, name: "saslScram512Auth", parent: name, min: 1)
                try self.validate(value, name: "saslScram512Auth", parent: name, pattern: "^(^arn:aws([a-z]|\\-)*:secretsmanager:([a-z]{2,4}((-gov)|(-de)|(-iso([a-z]?)))?-[a-z]+(-\\d{1})?):(\\d{12}):secret:.+)$")
            }
        }

        private enum CodingKeys: String, CodingKey {
            case basicAuth = "BasicAuth"
            case clientCertificateTlsAuth = "ClientCertificateTlsAuth"
            case saslScram256Auth = "SaslScram256Auth"
            case saslScram512Auth = "SaslScram512Auth"
        }
    }

    // MARK: Shapes

    public struct AwsVpcConfiguration: AWSEncodableShape & AWSDecodableShape {
        /// Specifies whether the task's elastic network interface receives a public IP address. You can specify ENABLED only when LaunchType in EcsParameters is set to FARGATE.
        public let assignPublicIp: AssignPublicIp?
        /// Specifies the security groups associated with the task. These security groups must all be in the same VPC. You can specify as many as five security groups. If you do not specify a security group, the default security group for the VPC is used.
        public let securityGroups: [String]?
        /// Specifies the subnets associated with the task. These subnets must all be in the same VPC. You can specify as many as 16 subnets.
        public let subnets: [String]

        @inlinable
        public init(assignPublicIp: AssignPublicIp? = nil, securityGroups: [String]? = nil, subnets: [String]) {
            self.assignPublicIp = assignPublicIp
            self.securityGroups = securityGroups
            self.subnets = subnets
        }

        public func validate(name: String) throws {
            try self.securityGroups?.forEach {
                try validate($0, name: "securityGroups[]", parent: name, max: 1024)
                try validate($0, name: "securityGroups[]", parent: name, min: 1)
                try validate($0, name: "securityGroups[]", parent: name, pattern: "^sg-[0-9a-zA-Z]*|(\\$(\\.[\\w/_-]+(\\[(\\d+|\\*)\\])*)*)$")
            }
            try self.validate(self.securityGroups, name: "securityGroups", parent: name, max: 5)
            try self.subnets.forEach {
                try validate($0, name: "subnets[]", parent: name, max: 1024)
                try validate($0, name: "subnets[]", parent: name, min: 1)
                try validate($0, name: "subnets[]", parent: name, pattern: "^subnet-[0-9a-z]*|(\\$(\\.[\\w/_-]+(\\[(\\d+|\\*)\\])*)*)$")
            }
            try self.validate(self.subnets, name: "subnets", parent: name, max: 16)
        }

        private enum CodingKeys: String, CodingKey {
            case assignPublicIp = "AssignPublicIp"
            case securityGroups = "SecurityGroups"
            case subnets = "Subnets"
        }
    }

    public struct BatchArrayProperties: AWSEncodableShape & AWSDecodableShape {
        /// The size of the array, if this is an array batch job.
        public let size: Int?

        @inlinable
        public init(size: Int? = nil) {
            self.size = size
        }

        public func validate(name: String) throws {
            try self.validate(self.size, name: "size", parent: name, max: 10000)
            try self.validate(self.size, name: "size", parent: name, min: 2)
        }

        private enum CodingKeys: String, CodingKey {
            case size = "Size"
        }
    }

    public struct BatchContainerOverrides: AWSEncodableShape & AWSDecodableShape {
        /// The command to send to the container that overrides the default command from the Docker image or the task definition.
        public let command: [String]?
        /// The environment variables to send to the container. You can add new environment variables, which are added to the container at launch, or you can override the existing environment variables from the Docker image or the task definition.  Environment variables cannot start with "Batch". This naming convention is reserved for variables that Batch sets.
        public let environment: [BatchEnvironmentVariable]?
        /// The instance type to use for a multi-node parallel job.  This parameter isn't applicable to single-node container jobs or jobs that run on Fargate resources, and shouldn't be provided.
        public let instanceType: String?
        /// The type and amount of resources to assign to a container. This overrides the settings in the job definition. The supported resources include GPU, MEMORY, and VCPU.
        public let resourceRequirements: [BatchResourceRequirement]?

        @inlinable
        public init(command: [String]? = nil, environment: [BatchEnvironmentVariable]? = nil, instanceType: String? = nil, resourceRequirements: [BatchResourceRequirement]? = nil) {
            self.command = command
            self.environment = environment
            self.instanceType = instanceType
            self.resourceRequirements = resourceRequirements
        }

        private enum CodingKeys: String, CodingKey {
            case command = "Command"
            case environment = "Environment"
            case instanceType = "InstanceType"
            case resourceRequirements = "ResourceRequirements"
        }
    }

    public struct BatchEnvironmentVariable: AWSEncodableShape & AWSDecodableShape {
        /// The name of the key-value pair. For environment variables, this is the name of the environment variable.
        public let name: String?
        /// The value of the key-value pair. For environment variables, this is the value of the environment variable.
        public let value: String?

        @inlinable
        public init(name: String? = nil, value: String? = nil) {
            self.name = name
            self.value = value
        }

        private enum CodingKeys: String, CodingKey {
            case name = "Name"
            case value = "Value"
        }
    }

    public struct BatchJobDependency: AWSEncodableShape & AWSDecodableShape {
        /// The job ID of the Batch job that's associated with this dependency.
        public let jobId: String?
        /// The type of the job dependency.
        public let type: BatchJobDependencyType?

        @inlinable
        public init(jobId: String? = nil, type: BatchJobDependencyType? = nil) {
            self.jobId = jobId
            self.type = type
        }

        private enum CodingKeys: String, CodingKey {
            case jobId = "JobId"
            case type = "Type"
        }
    }

    public struct BatchResourceRequirement: AWSEncodableShape & AWSDecodableShape {
        /// The type of resource to assign to a container. The supported resources include GPU, MEMORY, and VCPU.
        public let type: BatchResourceRequirementType
        /// The quantity of the specified resource to reserve for the container. The values vary based on the type specified.  type="GPU"  The number of physical GPUs to reserve for the container. Make sure that the number of GPUs reserved for all containers in a job doesn't exceed the number of available GPUs on the compute resource that the job is launched on.  GPUs aren't available for jobs that are running on Fargate resources.   type="MEMORY"  The memory hard limit (in MiB) present to the container. This parameter is supported for jobs that are running on EC2 resources. If your container attempts to exceed the memory specified, the container is terminated. This parameter maps to Memory in the  Create a container section of the Docker Remote API and the --memory option to docker run. You must specify at least 4 MiB of memory for a job. This is required but can be specified in several places for multi-node parallel (MNP) jobs. It must be specified for each node at least once. This parameter maps to Memory in the  Create a container section of the Docker Remote API and the --memory option to docker run.  If you're trying to maximize your resource utilization by providing your jobs as much memory as possible for a particular instance type, see Memory management in the Batch User Guide.  For jobs that are running on Fargate resources, then value is the hard limit (in MiB), and must match one of the supported values and the VCPU values must be one of the values supported for that memory value.  value = 512   VCPU = 0.25  value = 1024   VCPU = 0.25 or 0.5  value = 2048   VCPU = 0.25, 0.5, or 1  value = 3072   VCPU = 0.5, or 1  value = 4096   VCPU = 0.5, 1, or 2  value = 5120, 6144, or 7168   VCPU = 1 or 2  value = 8192   VCPU = 1, 2, 4, or 8  value = 9216, 10240, 11264, 12288, 13312, 14336, or 15360   VCPU = 2 or 4  value = 16384   VCPU = 2, 4, or 8  value = 17408, 18432, 19456, 21504, 22528, 23552, 25600, 26624, 27648, 29696, or 30720   VCPU = 4  value = 20480, 24576, or 28672   VCPU = 4 or 8  value = 36864, 45056, 53248, or 61440   VCPU = 8  value = 32768, 40960, 49152, or 57344   VCPU = 8 or 16  value = 65536, 73728, 81920, 90112, 98304, 106496, 114688, or 122880   VCPU = 16    type="VCPU"  The number of vCPUs reserved for the container. This parameter maps to CpuShares in the  Create a container section of the Docker Remote API and the --cpu-shares option to docker run. Each vCPU is equivalent to 1,024 CPU shares. For EC2 resources, you must specify at least one vCPU. This is required but can be specified in several places; it must be specified for each node at least once. The default for the Fargate On-Demand vCPU resource count quota is 6 vCPUs. For more information about Fargate quotas, see Fargate quotas in the Amazon Web Services General Reference. For jobs that are running on Fargate resources, then value must match one of the supported values and the MEMORY values must be one of the values supported for that VCPU value. The supported values are 0.25, 0.5, 1, 2, 4, 8, and 16  value = 0.25   MEMORY = 512, 1024, or 2048  value = 0.5   MEMORY = 1024, 2048, 3072, or 4096  value = 1   MEMORY = 2048, 3072, 4096, 5120, 6144, 7168, or 8192  value = 2   MEMORY = 4096, 5120, 6144, 7168, 8192, 9216, 10240, 11264, 12288, 13312, 14336, 15360, or 16384  value = 4   MEMORY = 8192, 9216, 10240, 11264, 12288, 13312, 14336, 15360, 16384, 17408, 18432, 19456, 20480, 21504, 22528, 23552, 24576, 25600, 26624, 27648, 28672, 29696, or 30720  value = 8   MEMORY = 16384, 20480, 24576, 28672, 32768, 36864, 40960, 45056, 49152, 53248, 57344, or 61440   value = 16   MEMORY = 32768, 40960, 49152, 57344, 65536, 73728, 81920, 90112, 98304, 106496, 114688, or 122880
        public let value: String

        @inlinable
        public init(type: BatchResourceRequirementType, value: String) {
            self.type = type
            self.value = value
        }

        private enum CodingKeys: String, CodingKey {
            case type = "Type"
            case value = "Value"
        }
    }

    public struct BatchRetryStrategy: AWSEncodableShape & AWSDecodableShape {
        /// The number of times to move a job to the RUNNABLE status. If the value of attempts is greater than one, the job is retried on failure the same number of attempts as the value.
        public let attempts: Int?

        @inlinable
        public init(attempts: Int? = nil) {
            self.attempts = attempts
        }

        public func validate(name: String) throws {
            try self.validate(self.attempts, name: "attempts", parent: name, max: 10)
            try self.validate(self.attempts, name: "attempts", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case attempts = "Attempts"
        }
    }

    public struct CapacityProviderStrategyItem: AWSEncodableShape & AWSDecodableShape {
        /// The base value designates how many tasks, at a minimum, to run on the specified capacity provider. Only one capacity provider in a capacity provider strategy can have a base defined. If no value is specified, the default value of 0 is used.
        public let base: Int?
        /// The short name of the capacity provider.
        public let capacityProvider: String
        /// The weight value designates the relative percentage of the total number of tasks launched that should use the specified capacity provider. The weight value is taken into consideration after the base value, if defined, is satisfied.
        public let weight: Int?

        @inlinable
        public init(base: Int? = nil, capacityProvider: String, weight: Int? = nil) {
            self.base = base
            self.capacityProvider = capacityProvider
            self.weight = weight
        }

        public func validate(name: String) throws {
            try self.validate(self.base, name: "base", parent: name, max: 100000)
            try self.validate(self.base, name: "base", parent: name, min: 0)
            try self.validate(self.capacityProvider, name: "capacityProvider", parent: name, max: 255)
            try self.validate(self.capacityProvider, name: "capacityProvider", parent: name, min: 1)
            try self.validate(self.weight, name: "weight", parent: name, max: 1000)
            try self.validate(self.weight, name: "weight", parent: name, min: 0)
        }

        private enum CodingKeys: String, CodingKey {
            case base = "base"
            case capacityProvider = "capacityProvider"
            case weight = "weight"
        }
    }

    public struct CloudwatchLogsLogDestination: AWSDecodableShape {
        /// The Amazon Web Services Resource Name (ARN) for the CloudWatch log group to which EventBridge sends the log records.
        public let logGroupArn: String?

        @inlinable
        public init(logGroupArn: String? = nil) {
            self.logGroupArn = logGroupArn
        }

        private enum CodingKeys: String, CodingKey {
            case logGroupArn = "LogGroupArn"
        }
    }

    public struct CloudwatchLogsLogDestinationParameters: AWSEncodableShape {
        /// The Amazon Web Services Resource Name (ARN) for the CloudWatch log group to which EventBridge sends the log records.
        public let logGroupArn: String

        @inlinable
        public init(logGroupArn: String) {
            self.logGroupArn = logGroupArn
        }

        public func validate(name: String) throws {
            try self.validate(self.logGroupArn, name: "logGroupArn", parent: name, max: 1600)
            try self.validate(self.logGroupArn, name: "logGroupArn", parent: name, min: 1)
            try self.validate(self.logGroupArn, name: "logGroupArn", parent: name, pattern: "^(^arn:aws([a-z]|\\-)*:logs:([a-z]{2,4}((-gov)|(-de)|(-iso([a-z]?)))?-[a-z]+(-\\d{1})?):(\\d{12}):log-group:[\\.\\-_/#A-Za-z0-9]{1,512}(:\\*)?)$")
        }

        private enum CodingKeys: String, CodingKey {
            case logGroupArn = "LogGroupArn"
        }
    }

    public struct ConflictException: AWSErrorShape {
        public let message: String
        /// The ID of the resource that caused the exception.
        public let resourceId: String
        /// The type of resource that caused the exception.
        public let resourceType: String

        @inlinable
        public init(message: String, resourceId: String, resourceType: String) {
            self.message = message
            self.resourceId = resourceId
            self.resourceType = resourceType
        }

        private enum CodingKeys: String, CodingKey {
            case message = "message"
            case resourceId = "resourceId"
            case resourceType = "resourceType"
        }
    }

    public struct CreatePipeRequest: AWSEncodableShape {
        /// A description of the pipe.
        public let description: String?
        /// The state the pipe should be in.
        public let desiredState: RequestedPipeState?
        /// The ARN of the enrichment resource.
        public let enrichment: String?
        /// The parameters required to set up enrichment on your pipe.
        public let enrichmentParameters: PipeEnrichmentParameters?
        /// The identifier of the KMS customer managed key for EventBridge to use, if you choose to use a customer managed key to encrypt pipe data. The identifier can be the key  Amazon Resource Name (ARN), KeyId, key alias, or key alias ARN. If you do not specify a customer managed key identifier, EventBridge uses an Amazon Web Services owned key to encrypt pipe data. For more information, see Managing keys in the Key Management Service Developer Guide.
        public let kmsKeyIdentifier: String?
        /// The logging configuration settings for the pipe.
        public let logConfiguration: PipeLogConfigurationParameters?
        /// The name of the pipe.
        public let name: String
        /// The ARN of the role that allows the pipe to send data to the target.
        public let roleArn: String
        /// The ARN of the source resource.
        public let source: String
        /// The parameters required to set up a source for your pipe.
        public let sourceParameters: PipeSourceParameters?
        /// The list of key-value pairs to associate with the pipe.
        public let tags: [String: String]?
        /// The ARN of the target resource.
        public let target: String
        /// The parameters required to set up a target for your pipe. For more information about pipe target parameters, including how to use dynamic path parameters, see Target parameters in the Amazon EventBridge User Guide.
        public let targetParameters: PipeTargetParameters?

        @inlinable
        public init(description: String? = nil, desiredState: RequestedPipeState? = nil, enrichment: String? = nil, enrichmentParameters: PipeEnrichmentParameters? = nil, kmsKeyIdentifier: String? = nil, logConfiguration: PipeLogConfigurationParameters? = nil, name: String, roleArn: String, source: String, sourceParameters: PipeSourceParameters? = nil, tags: [String: String]? = nil, target: String, targetParameters: PipeTargetParameters? = nil) {
            self.description = description
            self.desiredState = desiredState
            self.enrichment = enrichment
            self.enrichmentParameters = enrichmentParameters
            self.kmsKeyIdentifier = kmsKeyIdentifier
            self.logConfiguration = logConfiguration
            self.name = name
            self.roleArn = roleArn
            self.source = source
            self.sourceParameters = sourceParameters
            self.tags = tags
            self.target = target
            self.targetParameters = targetParameters
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            try container.encodeIfPresent(self.description, forKey: .description)
            try container.encodeIfPresent(self.desiredState, forKey: .desiredState)
            try container.encodeIfPresent(self.enrichment, forKey: .enrichment)
            try container.encodeIfPresent(self.enrichmentParameters, forKey: .enrichmentParameters)
            try container.encodeIfPresent(self.kmsKeyIdentifier, forKey: .kmsKeyIdentifier)
            try container.encodeIfPresent(self.logConfiguration, forKey: .logConfiguration)
            request.encodePath(self.name, key: "Name")
            try container.encode(self.roleArn, forKey: .roleArn)
            try container.encode(self.source, forKey: .source)
            try container.encodeIfPresent(self.sourceParameters, forKey: .sourceParameters)
            try container.encodeIfPresent(self.tags, forKey: .tags)
            try container.encode(self.target, forKey: .target)
            try container.encodeIfPresent(self.targetParameters, forKey: .targetParameters)
        }

        public func validate(name: String) throws {
            try self.validate(self.description, name: "description", parent: name, max: 512)
            try self.validate(self.description, name: "description", parent: name, pattern: "^.*$")
            try self.validate(self.enrichment, name: "enrichment", parent: name, max: 1600)
            try self.validate(self.enrichment, name: "enrichment", parent: name, pattern: "^$|arn:(aws[a-zA-Z0-9-]*):([a-zA-Z0-9\\-]+):([a-z]{2,4}((-gov)|(-de)|(-iso([a-z]?)))?-[a-z]+(-\\d{1})?)?:(\\d{12})?:(.+)$")
            try self.enrichmentParameters?.validate(name: "\(name).enrichmentParameters")
            try self.validate(self.kmsKeyIdentifier, name: "kmsKeyIdentifier", parent: name, max: 2048)
            try self.validate(self.kmsKeyIdentifier, name: "kmsKeyIdentifier", parent: name, pattern: "^[a-zA-Z0-9_\\-/:]*$")
            try self.logConfiguration?.validate(name: "\(name).logConfiguration")
            try self.validate(self.name, name: "name", parent: name, max: 64)
            try self.validate(self.name, name: "name", parent: name, min: 1)
            try self.validate(self.name, name: "name", parent: name, pattern: "^[\\.\\-_A-Za-z0-9]+$")
            try self.validate(self.roleArn, name: "roleArn", parent: name, max: 1600)
            try self.validate(self.roleArn, name: "roleArn", parent: name, min: 1)
            try self.validate(self.roleArn, name: "roleArn", parent: name, pattern: "^arn:(aws[a-zA-Z-]*)?:iam::\\d{12}:role/?[a-zA-Z0-9+=,.@\\-_/]+$")
            try self.validate(self.source, name: "source", parent: name, max: 1600)
            try self.validate(self.source, name: "source", parent: name, min: 1)
            try self.validate(self.source, name: "source", parent: name, pattern: "^smk://(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\\-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9\\-]*[A-Za-z0-9]):[0-9]{1,5}|arn:(aws[a-zA-Z0-9-]*):([a-zA-Z0-9\\-]+):([a-z]{2,4}((-gov)|(-de)|(-iso([a-z]?)))?-[a-z]+(-\\d{1})?)?:(\\d{12})?:(.+)$")
            try self.sourceParameters?.validate(name: "\(name).sourceParameters")
            try self.tags?.forEach {
                try validate($0.key, name: "tags.key", parent: name, max: 128)
                try validate($0.key, name: "tags.key", parent: name, min: 1)
                try validate($0.value, name: "tags[\"\($0.key)\"]", parent: name, max: 256)
            }
            try self.validate(self.tags, name: "tags", parent: name, max: 50)
            try self.validate(self.tags, name: "tags", parent: name, min: 1)
            try self.validate(self.target, name: "target", parent: name, max: 1600)
            try self.validate(self.target, name: "target", parent: name, min: 1)
            try self.validate(self.target, name: "target", parent: name, pattern: "^arn:(aws[a-zA-Z0-9-]*):([a-zA-Z0-9\\-]+):([a-z]{2,4}((-gov)|(-de)|(-iso([a-z]?)))?-[a-z]+(-\\d{1})?)?:(\\d{12})?:(.+)$")
            try self.targetParameters?.validate(name: "\(name).targetParameters")
        }

        private enum CodingKeys: String, CodingKey {
            case description = "Description"
            case desiredState = "DesiredState"
            case enrichment = "Enrichment"
            case enrichmentParameters = "EnrichmentParameters"
            case kmsKeyIdentifier = "KmsKeyIdentifier"
            case logConfiguration = "LogConfiguration"
            case roleArn = "RoleArn"
            case source = "Source"
            case sourceParameters = "SourceParameters"
            case tags = "Tags"
            case target = "Target"
            case targetParameters = "TargetParameters"
        }
    }

    public struct CreatePipeResponse: AWSDecodableShape {
        /// The ARN of the pipe.
        public let arn: String?
        /// The time the pipe was created.
        public let creationTime: Date?
        /// The state the pipe is in.
        public let currentState: PipeState?
        /// The state the pipe should be in.
        public let desiredState: RequestedPipeState?
        /// When the pipe was last updated, in ISO-8601 format (YYYY-MM-DDThh:mm:ss.sTZD).
        public let lastModifiedTime: Date?
        /// The name of the pipe.
        public let name: String?

        @inlinable
        public init(arn: String? = nil, creationTime: Date? = nil, currentState: PipeState? = nil, desiredState: RequestedPipeState? = nil, lastModifiedTime: Date? = nil, name: String? = nil) {
            self.arn = arn
            self.creationTime = creationTime
            self.currentState = currentState
            self.desiredState = desiredState
            self.lastModifiedTime = lastModifiedTime
            self.name = name
        }

        private enum CodingKeys: String, CodingKey {
            case arn = "Arn"
            case creationTime = "CreationTime"
            case currentState = "CurrentState"
            case desiredState = "DesiredState"
            case lastModifiedTime = "LastModifiedTime"
            case name = "Name"
        }
    }

    public struct DeadLetterConfig: AWSEncodableShape & AWSDecodableShape {
        /// The ARN of the specified target for the dead-letter queue.  For Amazon Kinesis stream and Amazon DynamoDB stream sources, specify either an Amazon SNS topic or Amazon SQS queue ARN.
        public let arn: String?

        @inlinable
        public init(arn: String? = nil) {
            self.arn = arn
        }

        public func validate(name: String) throws {
            try self.validate(self.arn, name: "arn", parent: name, max: 1600)
            try self.validate(self.arn, name: "arn", parent: name, min: 1)
            try self.validate(self.arn, name: "arn", parent: name, pattern: "^arn:(aws[a-zA-Z0-9-]*):([a-zA-Z0-9\\-]+):([a-z]{2,4}((-gov)|(-de)|(-iso([a-z]?)))?-[a-z]+(-\\d{1})?)?:(\\d{12})?:(.+)$")
        }

        private enum CodingKeys: String, CodingKey {
            case arn = "Arn"
        }
    }

    public struct DeletePipeRequest: AWSEncodableShape {
        /// The name of the pipe.
        public let name: String

        @inlinable
        public init(name: String) {
            self.name = name
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.name, key: "Name")
        }

        public func validate(name: String) throws {
            try self.validate(self.name, name: "name", parent: name, max: 64)
            try self.validate(self.name, name: "name", parent: name, min: 1)
            try self.validate(self.name, name: "name", parent: name, pattern: "^[\\.\\-_A-Za-z0-9]+$")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct DeletePipeResponse: AWSDecodableShape {
        /// The ARN of the pipe.
        public let arn: String?
        /// The time the pipe was created.
        public let creationTime: Date?
        /// The state the pipe is in.
        public let currentState: PipeState?
        /// The state the pipe should be in.
        public let desiredState: RequestedPipeStateDescribeResponse?
        /// When the pipe was last updated, in ISO-8601 format (YYYY-MM-DDThh:mm:ss.sTZD).
        public let lastModifiedTime: Date?
        /// The name of the pipe.
        public let name: String?

        @inlinable
        public init(arn: String? = nil, creationTime: Date? = nil, currentState: PipeState? = nil, desiredState: RequestedPipeStateDescribeResponse? = nil, lastModifiedTime: Date? = nil, name: String? = nil) {
            self.arn = arn
            self.creationTime = creationTime
            self.currentState = currentState
            self.desiredState = desiredState
            self.lastModifiedTime = lastModifiedTime
            self.name = name
        }

        private enum CodingKeys: String, CodingKey {
            case arn = "Arn"
            case creationTime = "CreationTime"
            case currentState = "CurrentState"
            case desiredState = "DesiredState"
            case lastModifiedTime = "LastModifiedTime"
            case name = "Name"
        }
    }

    public struct DescribePipeRequest: AWSEncodableShape {
        /// The name of the pipe.
        public let name: String

        @inlinable
        public init(name: String) {
            self.name = name
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.name, key: "Name")
        }

        public func validate(name: String) throws {
            try self.validate(self.name, name: "name", parent: name, max: 64)
            try self.validate(self.name, name: "name", parent: name, min: 1)
            try self.validate(self.name, name: "name", parent: name, pattern: "^[\\.\\-_A-Za-z0-9]+$")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct DescribePipeResponse: AWSDecodableShape {
        /// The ARN of the pipe.
        public let arn: String?
        /// The time the pipe was created.
        public let creationTime: Date?
        /// The state the pipe is in.
        public let currentState: PipeState?
        /// A description of the pipe.
        public let description: String?
        /// The state the pipe should be in.
        public let desiredState: RequestedPipeStateDescribeResponse?
        /// The ARN of the enrichment resource.
        public let enrichment: String?
        /// The parameters required to set up enrichment on your pipe.
        public let enrichmentParameters: PipeEnrichmentParameters?
        /// The identifier of the KMS customer managed key for EventBridge to use to encrypt pipe data, if one has been specified. For more information, see Data encryption in EventBridge in the Amazon EventBridge User Guide.
        public let kmsKeyIdentifier: String?
        /// When the pipe was last updated, in ISO-8601 format (YYYY-MM-DDThh:mm:ss.sTZD).
        public let lastModifiedTime: Date?
        /// The logging configuration settings for the pipe.
        public let logConfiguration: PipeLogConfiguration?
        /// The name of the pipe.
        public let name: String?
        /// The ARN of the role that allows the pipe to send data to the target.
        public let roleArn: String?
        /// The ARN of the source resource.
        public let source: String?
        /// The parameters required to set up a source for your pipe.
        public let sourceParameters: PipeSourceParameters?
        /// The reason the pipe is in its current state.
        public let stateReason: String?
        /// The list of key-value pairs to associate with the pipe.
        public let tags: [String: String]?
        /// The ARN of the target resource.
        public let target: String?
        /// The parameters required to set up a target for your pipe. For more information about pipe target parameters, including how to use dynamic path parameters, see Target parameters in the Amazon EventBridge User Guide.
        public let targetParameters: PipeTargetParameters?

        @inlinable
        public init(arn: String? = nil, creationTime: Date? = nil, currentState: PipeState? = nil, description: String? = nil, desiredState: RequestedPipeStateDescribeResponse? = nil, enrichment: String? = nil, enrichmentParameters: PipeEnrichmentParameters? = nil, kmsKeyIdentifier: String? = nil, lastModifiedTime: Date? = nil, logConfiguration: PipeLogConfiguration? = nil, name: String? = nil, roleArn: String? = nil, source: String? = nil, sourceParameters: PipeSourceParameters? = nil, stateReason: String? = nil, tags: [String: String]? = nil, target: String? = nil, targetParameters: PipeTargetParameters? = nil) {
            self.arn = arn
            self.creationTime = creationTime
            self.currentState = currentState
            self.description = description
            self.desiredState = desiredState
            self.enrichment = enrichment
            self.enrichmentParameters = enrichmentParameters
            self.kmsKeyIdentifier = kmsKeyIdentifier
            self.lastModifiedTime = lastModifiedTime
            self.logConfiguration = logConfiguration
            self.name = name
            self.roleArn = roleArn
            self.source = source
            self.sourceParameters = sourceParameters
            self.stateReason = stateReason
            self.tags = tags
            self.target = target
            self.targetParameters = targetParameters
        }

        private enum CodingKeys: String, CodingKey {
            case arn = "Arn"
            case creationTime = "CreationTime"
            case currentState = "CurrentState"
            case description = "Description"
            case desiredState = "DesiredState"
            case enrichment = "Enrichment"
            case enrichmentParameters = "EnrichmentParameters"
            case kmsKeyIdentifier = "KmsKeyIdentifier"
            case lastModifiedTime = "LastModifiedTime"
            case logConfiguration = "LogConfiguration"
            case name = "Name"
            case roleArn = "RoleArn"
            case source = "Source"
            case sourceParameters = "SourceParameters"
            case stateReason = "StateReason"
            case tags = "Tags"
            case target = "Target"
            case targetParameters = "TargetParameters"
        }
    }

    public struct DimensionMapping: AWSEncodableShape & AWSDecodableShape {
        /// The metadata attributes of the time series. For example, the name and Availability Zone of an Amazon EC2 instance or the name of the manufacturer of a wind turbine are dimensions.
        public let dimensionName: String
        /// Dynamic path to the dimension value in the source event.
        public let dimensionValue: String
        /// The data type of the dimension for the time-series data.
        public let dimensionValueType: DimensionValueType

        @inlinable
        public init(dimensionName: String, dimensionValue: String, dimensionValueType: DimensionValueType) {
            self.dimensionName = dimensionName
            self.dimensionValue = dimensionValue
            self.dimensionValueType = dimensionValueType
        }

        public func validate(name: String) throws {
            try self.validate(self.dimensionName, name: "dimensionName", parent: name, max: 256)
            try self.validate(self.dimensionName, name: "dimensionName", parent: name, min: 1)
            try self.validate(self.dimensionValue, name: "dimensionValue", parent: name, max: 2048)
            try self.validate(self.dimensionValue, name: "dimensionValue", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case dimensionName = "DimensionName"
            case dimensionValue = "DimensionValue"
            case dimensionValueType = "DimensionValueType"
        }
    }

    public struct EcsContainerOverride: AWSEncodableShape & AWSDecodableShape {
        /// The command to send to the container that overrides the default command from the Docker image or the task definition. You must also specify a container name.
        public let command: [String]?
        /// The number of cpu units reserved for the container, instead of the default value from the task definition. You must also specify a container name.
        public let cpu: Int?
        /// The environment variables to send to the container. You can add new environment variables, which are added to the container at launch, or you can override the existing environment variables from the Docker image or the task definition. You must also specify a container name.
        public let environment: [EcsEnvironmentVariable]?
        /// A list of files containing the environment variables to pass to a container, instead of the value from the container definition.
        public let environmentFiles: [EcsEnvironmentFile]?
        /// The hard limit (in MiB) of memory to present to the container, instead of the default value from the task definition. If your container attempts to exceed the memory specified here, the container is killed. You must also specify a container name.
        public let memory: Int?
        /// The soft limit (in MiB) of memory to reserve for the container, instead of the default value from the task definition. You must also specify a container name.
        public let memoryReservation: Int?
        /// The name of the container that receives the override. This parameter is required if any override is specified.
        public let name: String?
        /// The type and amount of a resource to assign to a container, instead of the default value from the task definition. The only supported resource is a GPU.
        public let resourceRequirements: [EcsResourceRequirement]?

        @inlinable
        public init(command: [String]? = nil, cpu: Int? = nil, environment: [EcsEnvironmentVariable]? = nil, environmentFiles: [EcsEnvironmentFile]? = nil, memory: Int? = nil, memoryReservation: Int? = nil, name: String? = nil, resourceRequirements: [EcsResourceRequirement]? = nil) {
            self.command = command
            self.cpu = cpu
            self.environment = environment
            self.environmentFiles = environmentFiles
            self.memory = memory
            self.memoryReservation = memoryReservation
            self.name = name
            self.resourceRequirements = resourceRequirements
        }

        private enum CodingKeys: String, CodingKey {
            case command = "Command"
            case cpu = "Cpu"
            case environment = "Environment"
            case environmentFiles = "EnvironmentFiles"
            case memory = "Memory"
            case memoryReservation = "MemoryReservation"
            case name = "Name"
            case resourceRequirements = "ResourceRequirements"
        }
    }

    public struct EcsEnvironmentFile: AWSEncodableShape & AWSDecodableShape {
        /// The file type to use. The only supported value is s3.
        public let type: EcsEnvironmentFileType
        /// The Amazon Resource Name (ARN) of the Amazon S3 object containing the environment variable file.
        public let value: String

        @inlinable
        public init(type: EcsEnvironmentFileType, value: String) {
            self.type = type
            self.value = value
        }

        private enum CodingKeys: String, CodingKey {
            case type = "type"
            case value = "value"
        }
    }

    public struct EcsEnvironmentVariable: AWSEncodableShape & AWSDecodableShape {
        /// The name of the key-value pair. For environment variables, this is the name of the environment variable.
        public let name: String?
        /// The value of the key-value pair. For environment variables, this is the value of the environment variable.
        public let value: String?

        @inlinable
        public init(name: String? = nil, value: String? = nil) {
            self.name = name
            self.value = value
        }

        private enum CodingKeys: String, CodingKey {
            case name = "name"
            case value = "value"
        }
    }

    public struct EcsEphemeralStorage: AWSEncodableShape & AWSDecodableShape {
        /// The total amount, in GiB, of ephemeral storage to set for the task. The minimum supported value is 21 GiB and the maximum supported value is 200 GiB.
        public let sizeInGiB: Int

        @inlinable
        public init(sizeInGiB: Int) {
            self.sizeInGiB = sizeInGiB
        }

        public func validate(name: String) throws {
            try self.validate(self.sizeInGiB, name: "sizeInGiB", parent: name, max: 200)
            try self.validate(self.sizeInGiB, name: "sizeInGiB", parent: name, min: 21)
        }

        private enum CodingKeys: String, CodingKey {
            case sizeInGiB = "sizeInGiB"
        }
    }

    public struct EcsInferenceAcceleratorOverride: AWSEncodableShape & AWSDecodableShape {
        /// The Elastic Inference accelerator device name to override for the task. This parameter must match a deviceName specified in the task definition.
        public let deviceName: String?
        /// The Elastic Inference accelerator type to use.
        public let deviceType: String?

        @inlinable
        public init(deviceName: String? = nil, deviceType: String? = nil) {
            self.deviceName = deviceName
            self.deviceType = deviceType
        }

        private enum CodingKeys: String, CodingKey {
            case deviceName = "deviceName"
            case deviceType = "deviceType"
        }
    }

    public struct EcsResourceRequirement: AWSEncodableShape & AWSDecodableShape {
        /// The type of resource to assign to a container. The supported values are GPU or InferenceAccelerator.
        public let type: EcsResourceRequirementType
        /// The value for the specified resource type. If the GPU type is used, the value is the number of physical GPUs the Amazon ECS container agent reserves for the container. The number of GPUs that's reserved for all containers in a task can't exceed the number of available GPUs on the container instance that the task is launched on. If the InferenceAccelerator type is used, the value matches the deviceName for an InferenceAccelerator specified in a task definition.
        public let value: String

        @inlinable
        public init(type: EcsResourceRequirementType, value: String) {
            self.type = type
            self.value = value
        }

        private enum CodingKeys: String, CodingKey {
            case type = "type"
            case value = "value"
        }
    }

    public struct EcsTaskOverride: AWSEncodableShape & AWSDecodableShape {
        /// One or more container overrides that are sent to a task.
        public let containerOverrides: [EcsContainerOverride]?
        /// The cpu override for the task.
        public let cpu: String?
        /// The ephemeral storage setting override for the task.  This parameter is only supported for tasks hosted on Fargate that use the following platform versions:   Linux platform version 1.4.0 or later.   Windows platform version 1.0.0 or later.
        public let ephemeralStorage: EcsEphemeralStorage?
        /// The Amazon Resource Name (ARN) of the task execution IAM role override for the task. For more information, see Amazon ECS task execution IAM role in the Amazon Elastic Container Service Developer Guide.
        public let executionRoleArn: String?
        /// The Elastic Inference accelerator override for the task.
        public let inferenceAcceleratorOverrides: [EcsInferenceAcceleratorOverride]?
        /// The memory override for the task.
        public let memory: String?
        /// The Amazon Resource Name (ARN) of the IAM role that containers in this task can assume. All containers in this task are granted the permissions that are specified in this role. For more information, see IAM Role for Tasks in the Amazon Elastic Container Service Developer Guide.
        public let taskRoleArn: String?

        @inlinable
        public init(containerOverrides: [EcsContainerOverride]? = nil, cpu: String? = nil, ephemeralStorage: EcsEphemeralStorage? = nil, executionRoleArn: String? = nil, inferenceAcceleratorOverrides: [EcsInferenceAcceleratorOverride]? = nil, memory: String? = nil, taskRoleArn: String? = nil) {
            self.containerOverrides = containerOverrides
            self.cpu = cpu
            self.ephemeralStorage = ephemeralStorage
            self.executionRoleArn = executionRoleArn
            self.inferenceAcceleratorOverrides = inferenceAcceleratorOverrides
            self.memory = memory
            self.taskRoleArn = taskRoleArn
        }

        public func validate(name: String) throws {
            try self.ephemeralStorage?.validate(name: "\(name).ephemeralStorage")
            try self.validate(self.executionRoleArn, name: "executionRoleArn", parent: name, max: 1600)
            try self.validate(self.executionRoleArn, name: "executionRoleArn", parent: name, min: 1)
            try self.validate(self.executionRoleArn, name: "executionRoleArn", parent: name, pattern: "^arn:(aws[a-zA-Z0-9-]*):([a-zA-Z0-9\\-]+):([a-z]{2,4}((-gov)|(-de)|(-iso([a-z]?)))?-[a-z]+(-\\d{1})?)?:(\\d{12})?:(.+)|(\\$(\\.[\\w/_-]+(\\[(\\d+|\\*)\\])*)*)$")
            try self.validate(self.taskRoleArn, name: "taskRoleArn", parent: name, max: 1600)
            try self.validate(self.taskRoleArn, name: "taskRoleArn", parent: name, min: 1)
            try self.validate(self.taskRoleArn, name: "taskRoleArn", parent: name, pattern: "^arn:(aws[a-zA-Z0-9-]*):([a-zA-Z0-9\\-]+):([a-z]{2,4}((-gov)|(-de)|(-iso([a-z]?)))?-[a-z]+(-\\d{1})?)?:(\\d{12})?:(.+)|(\\$(\\.[\\w/_-]+(\\[(\\d+|\\*)\\])*)*)$")
        }

        private enum CodingKeys: String, CodingKey {
            case containerOverrides = "ContainerOverrides"
            case cpu = "Cpu"
            case ephemeralStorage = "EphemeralStorage"
            case executionRoleArn = "ExecutionRoleArn"
            case inferenceAcceleratorOverrides = "InferenceAcceleratorOverrides"
            case memory = "Memory"
            case taskRoleArn = "TaskRoleArn"
        }
    }

    public struct Filter: AWSEncodableShape & AWSDecodableShape {
        /// The event pattern.
        public let pattern: String?

        @inlinable
        public init(pattern: String? = nil) {
            self.pattern = pattern
        }

        public func validate(name: String) throws {
            try self.validate(self.pattern, name: "pattern", parent: name, max: 4096)
        }

        private enum CodingKeys: String, CodingKey {
            case pattern = "Pattern"
        }
    }

    public struct FilterCriteria: AWSEncodableShape & AWSDecodableShape {
        /// The event patterns.
        public let filters: [Filter]?

        @inlinable
        public init(filters: [Filter]? = nil) {
            self.filters = filters
        }

        public func validate(name: String) throws {
            try self.filters?.forEach {
                try $0.validate(name: "\(name).filters[]")
            }
            try self.validate(self.filters, name: "filters", parent: name, max: 5)
        }

        private enum CodingKeys: String, CodingKey {
            case filters = "Filters"
        }
    }

    public struct FirehoseLogDestination: AWSDecodableShape {
        /// The Amazon Resource Name (ARN) of the Firehose delivery stream to which EventBridge delivers the pipe log records.
        public let deliveryStreamArn: String?

        @inlinable
        public init(deliveryStreamArn: String? = nil) {
            self.deliveryStreamArn = deliveryStreamArn
        }

        private enum CodingKeys: String, CodingKey {
            case deliveryStreamArn = "DeliveryStreamArn"
        }
    }

    public struct FirehoseLogDestinationParameters: AWSEncodableShape {
        /// Specifies the Amazon Resource Name (ARN) of the Firehose delivery stream to which EventBridge delivers the pipe log records.
        public let deliveryStreamArn: String

        @inlinable
        public init(deliveryStreamArn: String) {
            self.deliveryStreamArn = deliveryStreamArn
        }

        public func validate(name: String) throws {
            try self.validate(self.deliveryStreamArn, name: "deliveryStreamArn", parent: name, max: 1600)
            try self.validate(self.deliveryStreamArn, name: "deliveryStreamArn", parent: name, min: 1)
            try self.validate(self.deliveryStreamArn, name: "deliveryStreamArn", parent: name, pattern: "^(^arn:aws([a-z]|\\-)*:firehose:([a-z]{2,4}((-gov)|(-de)|(-iso([a-z]?)))?-[a-z]+(-\\d{1})?):(\\d{12}):deliverystream/[a-zA-Z0-9_.-]{1,64})$")
        }

        private enum CodingKeys: String, CodingKey {
            case deliveryStreamArn = "DeliveryStreamArn"
        }
    }

    public struct InternalException: AWSErrorShape {
        public let message: String
        /// The number of seconds to wait before retrying the action that caused the exception.
        public let retryAfterSeconds: Int?

        @inlinable
        public init(message: String, retryAfterSeconds: Int? = nil) {
            self.message = message
            self.retryAfterSeconds = retryAfterSeconds
        }

        public init(from decoder: Decoder) throws {
            let response = decoder.userInfo[.awsResponse]! as! ResponseDecodingContainer
            let container = try decoder.container(keyedBy: CodingKeys.self)
            self.message = try container.decode(String.self, forKey: .message)
            self.retryAfterSeconds = try response.decodeHeaderIfPresent(Int.self, key: "Retry-After")
        }

        private enum CodingKeys: String, CodingKey {
            case message = "message"
        }
    }

    public struct ListPipesRequest: AWSEncodableShape {
        /// The state the pipe is in.
        public let currentState: PipeState?
        /// The state the pipe should be in.
        public let desiredState: RequestedPipeState?
        /// The maximum number of pipes to include in the response.
        public let limit: Int?
        /// A value that will return a subset of the pipes associated with this account. For example, "NamePrefix": "ABC" will return all endpoints with "ABC" in the name.
        public let namePrefix: String?
        /// If nextToken is returned, there are more results available. The value of nextToken is a unique pagination token for each page.  Make the call again using the returned token to retrieve the next page. Keep all other arguments unchanged. Each pagination token expires after 24 hours. Using an expired pagination  token will return an HTTP 400 InvalidToken error.
        public let nextToken: String?
        /// The prefix matching the pipe source.
        public let sourcePrefix: String?
        /// The prefix matching the pipe target.
        public let targetPrefix: String?

        @inlinable
        public init(currentState: PipeState? = nil, desiredState: RequestedPipeState? = nil, limit: Int? = nil, namePrefix: String? = nil, nextToken: String? = nil, sourcePrefix: String? = nil, targetPrefix: String? = nil) {
            self.currentState = currentState
            self.desiredState = desiredState
            self.limit = limit
            self.namePrefix = namePrefix
            self.nextToken = nextToken
            self.sourcePrefix = sourcePrefix
            self.targetPrefix = targetPrefix
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.currentState, key: "CurrentState")
            request.encodeQuery(self.desiredState, key: "DesiredState")
            request.encodeQuery(self.limit, key: "Limit")
            request.encodeQuery(self.namePrefix, key: "NamePrefix")
            request.encodeQuery(self.nextToken, key: "NextToken")
            request.encodeQuery(self.sourcePrefix, key: "SourcePrefix")
            request.encodeQuery(self.targetPrefix, key: "TargetPrefix")
        }

        public func validate(name: String) throws {
            try self.validate(self.limit, name: "limit", parent: name, max: 100)
            try self.validate(self.limit, name: "limit", parent: name, min: 1)
            try self.validate(self.namePrefix, name: "namePrefix", parent: name, max: 64)
            try self.validate(self.namePrefix, name: "namePrefix", parent: name, min: 1)
            try self.validate(self.namePrefix, name: "namePrefix", parent: name, pattern: "^[\\.\\-_A-Za-z0-9]+$")
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 2048)
            try self.validate(self.nextToken, name: "nextToken", parent: name, min: 1)
            try self.validate(self.sourcePrefix, name: "sourcePrefix", parent: name, max: 1600)
            try self.validate(self.sourcePrefix, name: "sourcePrefix", parent: name, min: 1)
            try self.validate(self.targetPrefix, name: "targetPrefix", parent: name, max: 1600)
            try self.validate(self.targetPrefix, name: "targetPrefix", parent: name, min: 1)
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct ListPipesResponse: AWSDecodableShape {
        /// If nextToken is returned, there are more results available. The value of nextToken is a unique pagination token for each page.  Make the call again using the returned token to retrieve the next page. Keep all other arguments unchanged. Each pagination token expires after 24 hours. Using an expired pagination  token will return an HTTP 400 InvalidToken error.
        public let nextToken: String?
        /// The pipes returned by the call.
        public let pipes: [Pipe]?

        @inlinable
        public init(nextToken: String? = nil, pipes: [Pipe]? = nil) {
            self.nextToken = nextToken
            self.pipes = pipes
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
            case pipes = "Pipes"
        }
    }

    public struct ListTagsForResourceRequest: AWSEncodableShape {
        /// The ARN of the pipe for which you want to view tags.
        public let resourceArn: String

        @inlinable
        public init(resourceArn: String) {
            self.resourceArn = resourceArn
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.resourceArn, key: "resourceArn")
        }

        public func validate(name: String) throws {
            try self.validate(self.resourceArn, name: "resourceArn", parent: name, max: 1600)
            try self.validate(self.resourceArn, name: "resourceArn", parent: name, min: 1)
            try self.validate(self.resourceArn, name: "resourceArn", parent: name, pattern: "^arn:aws([a-z]|\\-)*:([a-zA-Z0-9\\-]+):([a-z]|\\d|\\-)*:([0-9]{12})?:(.+)$")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct ListTagsForResourceResponse: AWSDecodableShape {
        /// The list of key-value pairs to associate with the pipe.
        public let tags: [String: String]?

        @inlinable
        public init(tags: [String: String]? = nil) {
            self.tags = tags
        }

        private enum CodingKeys: String, CodingKey {
            case tags = "tags"
        }
    }

    public struct MultiMeasureAttributeMapping: AWSEncodableShape & AWSDecodableShape {
        /// Dynamic path to the measurement attribute in the source event.
        public let measureValue: String
        /// Data type of the measurement attribute in the source event.
        public let measureValueType: MeasureValueType
        /// Target measure name to be used.
        public let multiMeasureAttributeName: String

        @inlinable
        public init(measureValue: String, measureValueType: MeasureValueType, multiMeasureAttributeName: String) {
            self.measureValue = measureValue
            self.measureValueType = measureValueType
            self.multiMeasureAttributeName = multiMeasureAttributeName
        }

        public func validate(name: String) throws {
            try self.validate(self.measureValue, name: "measureValue", parent: name, max: 2048)
            try self.validate(self.measureValue, name: "measureValue", parent: name, min: 1)
            try self.validate(self.multiMeasureAttributeName, name: "multiMeasureAttributeName", parent: name, max: 256)
            try self.validate(self.multiMeasureAttributeName, name: "multiMeasureAttributeName", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case measureValue = "MeasureValue"
            case measureValueType = "MeasureValueType"
            case multiMeasureAttributeName = "MultiMeasureAttributeName"
        }
    }

    public struct MultiMeasureMapping: AWSEncodableShape & AWSDecodableShape {
        /// Mappings that represent multiple source event fields mapped to measures in the same Timestream for LiveAnalytics record.
        public let multiMeasureAttributeMappings: [MultiMeasureAttributeMapping]
        /// The name of the multiple measurements per record (multi-measure).
        public let multiMeasureName: String

        @inlinable
        public init(multiMeasureAttributeMappings: [MultiMeasureAttributeMapping], multiMeasureName: String) {
            self.multiMeasureAttributeMappings = multiMeasureAttributeMappings
            self.multiMeasureName = multiMeasureName
        }

        public func validate(name: String) throws {
            try self.multiMeasureAttributeMappings.forEach {
                try $0.validate(name: "\(name).multiMeasureAttributeMappings[]")
            }
            try self.validate(self.multiMeasureAttributeMappings, name: "multiMeasureAttributeMappings", parent: name, max: 256)
            try self.validate(self.multiMeasureAttributeMappings, name: "multiMeasureAttributeMappings", parent: name, min: 1)
            try self.validate(self.multiMeasureName, name: "multiMeasureName", parent: name, max: 256)
            try self.validate(self.multiMeasureName, name: "multiMeasureName", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case multiMeasureAttributeMappings = "MultiMeasureAttributeMappings"
            case multiMeasureName = "MultiMeasureName"
        }
    }

    public struct NetworkConfiguration: AWSEncodableShape & AWSDecodableShape {
        /// Use this structure to specify the VPC subnets and security groups for the task, and whether a public IP address is to be used. This structure is relevant only for ECS tasks that use the awsvpc network mode.
        public let awsvpcConfiguration: AwsVpcConfiguration?

        @inlinable
        public init(awsvpcConfiguration: AwsVpcConfiguration? = nil) {
            self.awsvpcConfiguration = awsvpcConfiguration
        }

        public func validate(name: String) throws {
            try self.awsvpcConfiguration?.validate(name: "\(name).awsvpcConfiguration")
        }

        private enum CodingKeys: String, CodingKey {
            case awsvpcConfiguration = "awsvpcConfiguration"
        }
    }

    public struct Pipe: AWSDecodableShape {
        /// The ARN of the pipe.
        public let arn: String?
        /// The time the pipe was created.
        public let creationTime: Date?
        /// The state the pipe is in.
        public let currentState: PipeState?
        /// The state the pipe should be in.
        public let desiredState: RequestedPipeState?
        /// The ARN of the enrichment resource.
        public let enrichment: String?
        /// When the pipe was last updated, in ISO-8601 format (YYYY-MM-DDThh:mm:ss.sTZD).
        public let lastModifiedTime: Date?
        /// The name of the pipe.
        public let name: String?
        /// The ARN of the source resource.
        public let source: String?
        /// The reason the pipe is in its current state.
        public let stateReason: String?
        /// The ARN of the target resource.
        public let target: String?

        @inlinable
        public init(arn: String? = nil, creationTime: Date? = nil, currentState: PipeState? = nil, desiredState: RequestedPipeState? = nil, enrichment: String? = nil, lastModifiedTime: Date? = nil, name: String? = nil, source: String? = nil, stateReason: String? = nil, target: String? = nil) {
            self.arn = arn
            self.creationTime = creationTime
            self.currentState = currentState
            self.desiredState = desiredState
            self.enrichment = enrichment
            self.lastModifiedTime = lastModifiedTime
            self.name = name
            self.source = source
            self.stateReason = stateReason
            self.target = target
        }

        private enum CodingKeys: String, CodingKey {
            case arn = "Arn"
            case creationTime = "CreationTime"
            case currentState = "CurrentState"
            case desiredState = "DesiredState"
            case enrichment = "Enrichment"
            case lastModifiedTime = "LastModifiedTime"
            case name = "Name"
            case source = "Source"
            case stateReason = "StateReason"
            case target = "Target"
        }
    }

    public struct PipeEnrichmentHttpParameters: AWSEncodableShape & AWSDecodableShape {
        /// The headers that need to be sent as part of request invoking the API Gateway REST API or EventBridge ApiDestination.
        public let headerParameters: [String: String]?
        /// The path parameter values to be used to populate API Gateway REST API or EventBridge ApiDestination path wildcards ("*").
        public let pathParameterValues: [String]?
        /// The query string keys/values that need to be sent as part of request invoking the API Gateway REST API or EventBridge ApiDestination.
        public let queryStringParameters: [String: String]?

        @inlinable
        public init(headerParameters: [String: String]? = nil, pathParameterValues: [String]? = nil, queryStringParameters: [String: String]? = nil) {
            self.headerParameters = headerParameters
            self.pathParameterValues = pathParameterValues
            self.queryStringParameters = queryStringParameters
        }

        public func validate(name: String) throws {
            try self.headerParameters?.forEach {
                try validate($0.key, name: "headerParameters.key", parent: name, max: 512)
                try validate($0.key, name: "headerParameters.key", parent: name, pattern: "^[!#$%&'*+-.^_`|~0-9a-zA-Z]+|(\\$(\\.[\\w/_-]+(\\[(\\d+|\\*)\\])*)*)$")
                try validate($0.value, name: "headerParameters[\"\($0.key)\"]", parent: name, max: 512)
                try validate($0.value, name: "headerParameters[\"\($0.key)\"]", parent: name, pattern: "^[ \\t]*[\\x20-\\x7E]+([ \\t]+[\\x20-\\x7E]+)*[ \\t]*|(\\$(\\.[\\w/_-]+(\\[(\\d+|\\*)\\])*)*)$")
            }
            try self.pathParameterValues?.forEach {
                try validate($0, name: "pathParameterValues[]", parent: name, pattern: "^(?!\\s*$).+|(\\$(\\.[\\w/_-]+(\\[(\\d+|\\*)\\])*)*)$")
            }
            try self.queryStringParameters?.forEach {
                try validate($0.key, name: "queryStringParameters.key", parent: name, max: 512)
                try validate($0.key, name: "queryStringParameters.key", parent: name, pattern: "^[^\\x00-\\x1F\\x7F]+|(\\$(\\.[\\w/_-]+(\\[(\\d+|\\*)\\])*)*)$")
                try validate($0.value, name: "queryStringParameters[\"\($0.key)\"]", parent: name, max: 512)
                try validate($0.value, name: "queryStringParameters[\"\($0.key)\"]", parent: name, pattern: "^[^\\x00-\\x09\\x0B\\x0C\\x0E-\\x1F\\x7F]+|(\\$(\\.[\\w/_-]+(\\[(\\d+|\\*)\\])*)*)$")
            }
        }

        private enum CodingKeys: String, CodingKey {
            case headerParameters = "HeaderParameters"
            case pathParameterValues = "PathParameterValues"
            case queryStringParameters = "QueryStringParameters"
        }
    }

    public struct PipeEnrichmentParameters: AWSEncodableShape & AWSDecodableShape {
        /// Contains the HTTP parameters to use when the target is a API Gateway REST endpoint or EventBridge ApiDestination. If you specify an API Gateway REST API or EventBridge ApiDestination as a target, you can use this parameter to specify headers, path parameters, and query string keys/values as part of your target invoking request. If you're using ApiDestinations, the corresponding Connection can also have these values configured. In case of any conflicting keys, values from the Connection take precedence.
        public let httpParameters: PipeEnrichmentHttpParameters?
        /// Valid JSON text passed to the enrichment. In this case, nothing from the event itself is passed to the enrichment. For more information, see The JavaScript Object Notation (JSON) Data Interchange Format. To remove an input template, specify an empty string.
        public let inputTemplate: String?

        @inlinable
        public init(httpParameters: PipeEnrichmentHttpParameters? = nil, inputTemplate: String? = nil) {
            self.httpParameters = httpParameters
            self.inputTemplate = inputTemplate
        }

        public func validate(name: String) throws {
            try self.httpParameters?.validate(name: "\(name).httpParameters")
            try self.validate(self.inputTemplate, name: "inputTemplate", parent: name, max: 8192)
        }

        private enum CodingKeys: String, CodingKey {
            case httpParameters = "HttpParameters"
            case inputTemplate = "InputTemplate"
        }
    }

    public struct PipeLogConfiguration: AWSDecodableShape {
        /// The Amazon CloudWatch Logs logging configuration settings for the pipe.
        public let cloudwatchLogsLogDestination: CloudwatchLogsLogDestination?
        /// The Amazon Data Firehose logging configuration settings for the pipe.
        public let firehoseLogDestination: FirehoseLogDestination?
        /// Whether the execution data (specifically, the payload, awsRequest, and awsResponse fields) is included in the log messages for this pipe. This applies to all log destinations for the pipe. For more information, see Including execution data in logs in the Amazon EventBridge User Guide.
        public let includeExecutionData: [IncludeExecutionDataOption]?
        /// The level of logging detail to include. This applies to all log destinations for the pipe.
        public let level: LogLevel?
        /// The Amazon S3 logging configuration settings for the pipe.
        public let s3LogDestination: S3LogDestination?

        @inlinable
        public init(cloudwatchLogsLogDestination: CloudwatchLogsLogDestination? = nil, firehoseLogDestination: FirehoseLogDestination? = nil, includeExecutionData: [IncludeExecutionDataOption]? = nil, level: LogLevel? = nil, s3LogDestination: S3LogDestination? = nil) {
            self.cloudwatchLogsLogDestination = cloudwatchLogsLogDestination
            self.firehoseLogDestination = firehoseLogDestination
            self.includeExecutionData = includeExecutionData
            self.level = level
            self.s3LogDestination = s3LogDestination
        }

        private enum CodingKeys: String, CodingKey {
            case cloudwatchLogsLogDestination = "CloudwatchLogsLogDestination"
            case firehoseLogDestination = "FirehoseLogDestination"
            case includeExecutionData = "IncludeExecutionData"
            case level = "Level"
            case s3LogDestination = "S3LogDestination"
        }
    }

    public struct PipeLogConfigurationParameters: AWSEncodableShape {
        /// The Amazon CloudWatch Logs logging configuration settings for the pipe.
        public let cloudwatchLogsLogDestination: CloudwatchLogsLogDestinationParameters?
        /// The Amazon Data Firehose logging configuration settings for the pipe.
        public let firehoseLogDestination: FirehoseLogDestinationParameters?
        /// Specify ALL to include the execution data (specifically, the payload, awsRequest, and awsResponse fields) in the log messages for this pipe. This applies to all log destinations for the pipe. For more information, see Including execution data in logs in the Amazon EventBridge User Guide. By default, execution data is not included.
        public let includeExecutionData: [IncludeExecutionDataOption]?
        /// The level of logging detail to include. This applies to all log destinations for the pipe. For more information, see Specifying EventBridge Pipes log level in the Amazon EventBridge User Guide.
        public let level: LogLevel
        /// The Amazon S3 logging configuration settings for the pipe.
        public let s3LogDestination: S3LogDestinationParameters?

        @inlinable
        public init(cloudwatchLogsLogDestination: CloudwatchLogsLogDestinationParameters? = nil, firehoseLogDestination: FirehoseLogDestinationParameters? = nil, includeExecutionData: [IncludeExecutionDataOption]? = nil, level: LogLevel, s3LogDestination: S3LogDestinationParameters? = nil) {
            self.cloudwatchLogsLogDestination = cloudwatchLogsLogDestination
            self.firehoseLogDestination = firehoseLogDestination
            self.includeExecutionData = includeExecutionData
            self.level = level
            self.s3LogDestination = s3LogDestination
        }

        public func validate(name: String) throws {
            try self.cloudwatchLogsLogDestination?.validate(name: "\(name).cloudwatchLogsLogDestination")
            try self.firehoseLogDestination?.validate(name: "\(name).firehoseLogDestination")
        }

        private enum CodingKeys: String, CodingKey {
            case cloudwatchLogsLogDestination = "CloudwatchLogsLogDestination"
            case firehoseLogDestination = "FirehoseLogDestination"
            case includeExecutionData = "IncludeExecutionData"
            case level = "Level"
            case s3LogDestination = "S3LogDestination"
        }
    }

    public struct PipeSourceActiveMQBrokerParameters: AWSEncodableShape & AWSDecodableShape {
        /// The maximum number of records to include in each batch.
        public let batchSize: Int?
        /// The credentials needed to access the resource.
        public let credentials: MQBrokerAccessCredentials
        /// The maximum length of a time to wait for events.
        public let maximumBatchingWindowInSeconds: Int?
        /// The name of the destination queue to consume.
        public let queueName: String

        @inlinable
        public init(batchSize: Int? = nil, credentials: MQBrokerAccessCredentials, maximumBatchingWindowInSeconds: Int? = nil, queueName: String) {
            self.batchSize = batchSize
            self.credentials = credentials
            self.maximumBatchingWindowInSeconds = maximumBatchingWindowInSeconds
            self.queueName = queueName
        }

        public func validate(name: String) throws {
            try self.validate(self.batchSize, name: "batchSize", parent: name, max: 10000)
            try self.validate(self.batchSize, name: "batchSize", parent: name, min: 1)
            try self.credentials.validate(name: "\(name).credentials")
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, max: 300)
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, min: 0)
            try self.validate(self.queueName, name: "queueName", parent: name, max: 1000)
            try self.validate(self.queueName, name: "queueName", parent: name, min: 1)
            try self.validate(self.queueName, name: "queueName", parent: name, pattern: "^[\\s\\S]*$")
        }

        private enum CodingKeys: String, CodingKey {
            case batchSize = "BatchSize"
            case credentials = "Credentials"
            case maximumBatchingWindowInSeconds = "MaximumBatchingWindowInSeconds"
            case queueName = "QueueName"
        }
    }

    public struct PipeSourceDynamoDBStreamParameters: AWSEncodableShape & AWSDecodableShape {
        /// The maximum number of records to include in each batch.
        public let batchSize: Int?
        /// Define the target queue to send dead-letter queue events to.
        public let deadLetterConfig: DeadLetterConfig?
        /// The maximum length of a time to wait for events.
        public let maximumBatchingWindowInSeconds: Int?
        /// Discard records older than the specified age. The default value is -1, which sets the maximum age to infinite.
        /// When the value is set to infinite, EventBridge never discards old records.
        public let maximumRecordAgeInSeconds: Int?
        /// Discard records after the specified number of retries. The default value is -1, which sets the maximum number of
        /// retries to infinite. When MaximumRetryAttempts is infinite, EventBridge retries failed records until the record expires in the event source.
        public let maximumRetryAttempts: Int?
        /// Define how to handle item process failures. AUTOMATIC_BISECT halves each batch and retry each half
        /// until all the records are processed or there is one failed message left in the batch.
        public let onPartialBatchItemFailure: OnPartialBatchItemFailureStreams?
        /// The number of batches to process concurrently from each shard. The default value is 1.
        public let parallelizationFactor: Int?
        /// The position in a stream from which to start reading.
        public let startingPosition: DynamoDBStreamStartPosition

        @inlinable
        public init(batchSize: Int? = nil, deadLetterConfig: DeadLetterConfig? = nil, maximumBatchingWindowInSeconds: Int? = nil, maximumRecordAgeInSeconds: Int? = nil, maximumRetryAttempts: Int? = nil, onPartialBatchItemFailure: OnPartialBatchItemFailureStreams? = nil, parallelizationFactor: Int? = nil, startingPosition: DynamoDBStreamStartPosition) {
            self.batchSize = batchSize
            self.deadLetterConfig = deadLetterConfig
            self.maximumBatchingWindowInSeconds = maximumBatchingWindowInSeconds
            self.maximumRecordAgeInSeconds = maximumRecordAgeInSeconds
            self.maximumRetryAttempts = maximumRetryAttempts
            self.onPartialBatchItemFailure = onPartialBatchItemFailure
            self.parallelizationFactor = parallelizationFactor
            self.startingPosition = startingPosition
        }

        public func validate(name: String) throws {
            try self.validate(self.batchSize, name: "batchSize", parent: name, max: 10000)
            try self.validate(self.batchSize, name: "batchSize", parent: name, min: 1)
            try self.deadLetterConfig?.validate(name: "\(name).deadLetterConfig")
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, max: 300)
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, min: 0)
            try self.validate(self.maximumRecordAgeInSeconds, name: "maximumRecordAgeInSeconds", parent: name, max: 604800)
            try self.validate(self.maximumRecordAgeInSeconds, name: "maximumRecordAgeInSeconds", parent: name, min: -1)
            try self.validate(self.maximumRetryAttempts, name: "maximumRetryAttempts", parent: name, max: 10000)
            try self.validate(self.maximumRetryAttempts, name: "maximumRetryAttempts", parent: name, min: -1)
            try self.validate(self.parallelizationFactor, name: "parallelizationFactor", parent: name, max: 10)
            try self.validate(self.parallelizationFactor, name: "parallelizationFactor", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case batchSize = "BatchSize"
            case deadLetterConfig = "DeadLetterConfig"
            case maximumBatchingWindowInSeconds = "MaximumBatchingWindowInSeconds"
            case maximumRecordAgeInSeconds = "MaximumRecordAgeInSeconds"
            case maximumRetryAttempts = "MaximumRetryAttempts"
            case onPartialBatchItemFailure = "OnPartialBatchItemFailure"
            case parallelizationFactor = "ParallelizationFactor"
            case startingPosition = "StartingPosition"
        }
    }

    public struct PipeSourceKinesisStreamParameters: AWSEncodableShape & AWSDecodableShape {
        /// The maximum number of records to include in each batch.
        public let batchSize: Int?
        /// Define the target queue to send dead-letter queue events to.
        public let deadLetterConfig: DeadLetterConfig?
        /// The maximum length of a time to wait for events.
        public let maximumBatchingWindowInSeconds: Int?
        /// Discard records older than the specified age. The default value is -1, which sets the maximum age to infinite.
        /// When the value is set to infinite, EventBridge never discards old records.
        public let maximumRecordAgeInSeconds: Int?
        /// Discard records after the specified number of retries. The default value is -1, which sets the maximum number of
        /// retries to infinite. When MaximumRetryAttempts is infinite, EventBridge retries failed records until the record expires in the event source.
        public let maximumRetryAttempts: Int?
        /// Define how to handle item process failures. AUTOMATIC_BISECT halves each batch and retry each half
        /// until all the records are processed or there is one failed message left in the batch.
        public let onPartialBatchItemFailure: OnPartialBatchItemFailureStreams?
        /// The number of batches to process concurrently from each shard. The default value is 1.
        public let parallelizationFactor: Int?
        /// The position in a stream from which to start reading.
        public let startingPosition: KinesisStreamStartPosition
        /// With StartingPosition set to AT_TIMESTAMP, the time from which to start reading, in Unix time seconds.
        public let startingPositionTimestamp: Date?

        @inlinable
        public init(batchSize: Int? = nil, deadLetterConfig: DeadLetterConfig? = nil, maximumBatchingWindowInSeconds: Int? = nil, maximumRecordAgeInSeconds: Int? = nil, maximumRetryAttempts: Int? = nil, onPartialBatchItemFailure: OnPartialBatchItemFailureStreams? = nil, parallelizationFactor: Int? = nil, startingPosition: KinesisStreamStartPosition, startingPositionTimestamp: Date? = nil) {
            self.batchSize = batchSize
            self.deadLetterConfig = deadLetterConfig
            self.maximumBatchingWindowInSeconds = maximumBatchingWindowInSeconds
            self.maximumRecordAgeInSeconds = maximumRecordAgeInSeconds
            self.maximumRetryAttempts = maximumRetryAttempts
            self.onPartialBatchItemFailure = onPartialBatchItemFailure
            self.parallelizationFactor = parallelizationFactor
            self.startingPosition = startingPosition
            self.startingPositionTimestamp = startingPositionTimestamp
        }

        public func validate(name: String) throws {
            try self.validate(self.batchSize, name: "batchSize", parent: name, max: 10000)
            try self.validate(self.batchSize, name: "batchSize", parent: name, min: 1)
            try self.deadLetterConfig?.validate(name: "\(name).deadLetterConfig")
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, max: 300)
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, min: 0)
            try self.validate(self.maximumRecordAgeInSeconds, name: "maximumRecordAgeInSeconds", parent: name, max: 604800)
            try self.validate(self.maximumRecordAgeInSeconds, name: "maximumRecordAgeInSeconds", parent: name, min: -1)
            try self.validate(self.maximumRetryAttempts, name: "maximumRetryAttempts", parent: name, max: 10000)
            try self.validate(self.maximumRetryAttempts, name: "maximumRetryAttempts", parent: name, min: -1)
            try self.validate(self.parallelizationFactor, name: "parallelizationFactor", parent: name, max: 10)
            try self.validate(self.parallelizationFactor, name: "parallelizationFactor", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case batchSize = "BatchSize"
            case deadLetterConfig = "DeadLetterConfig"
            case maximumBatchingWindowInSeconds = "MaximumBatchingWindowInSeconds"
            case maximumRecordAgeInSeconds = "MaximumRecordAgeInSeconds"
            case maximumRetryAttempts = "MaximumRetryAttempts"
            case onPartialBatchItemFailure = "OnPartialBatchItemFailure"
            case parallelizationFactor = "ParallelizationFactor"
            case startingPosition = "StartingPosition"
            case startingPositionTimestamp = "StartingPositionTimestamp"
        }
    }

    public struct PipeSourceManagedStreamingKafkaParameters: AWSEncodableShape & AWSDecodableShape {
        /// The maximum number of records to include in each batch.
        public let batchSize: Int?
        /// The name of the destination queue to consume.
        public let consumerGroupID: String?
        /// The credentials needed to access the resource.
        public let credentials: MSKAccessCredentials?
        /// The maximum length of a time to wait for events.
        public let maximumBatchingWindowInSeconds: Int?
        /// The position in a stream from which to start reading.
        public let startingPosition: MSKStartPosition?
        /// The name of the topic that the pipe will read from.
        public let topicName: String

        @inlinable
        public init(batchSize: Int? = nil, consumerGroupID: String? = nil, credentials: MSKAccessCredentials? = nil, maximumBatchingWindowInSeconds: Int? = nil, startingPosition: MSKStartPosition? = nil, topicName: String) {
            self.batchSize = batchSize
            self.consumerGroupID = consumerGroupID
            self.credentials = credentials
            self.maximumBatchingWindowInSeconds = maximumBatchingWindowInSeconds
            self.startingPosition = startingPosition
            self.topicName = topicName
        }

        public func validate(name: String) throws {
            try self.validate(self.batchSize, name: "batchSize", parent: name, max: 10000)
            try self.validate(self.batchSize, name: "batchSize", parent: name, min: 1)
            try self.validate(self.consumerGroupID, name: "consumerGroupID", parent: name, max: 200)
            try self.validate(self.consumerGroupID, name: "consumerGroupID", parent: name, min: 1)
            try self.validate(self.consumerGroupID, name: "consumerGroupID", parent: name, pattern: "^[a-zA-Z0-9-\\/*:_+=.@-]*$")
            try self.credentials?.validate(name: "\(name).credentials")
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, max: 300)
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, min: 0)
            try self.validate(self.topicName, name: "topicName", parent: name, max: 249)
            try self.validate(self.topicName, name: "topicName", parent: name, min: 1)
            try self.validate(self.topicName, name: "topicName", parent: name, pattern: "^[^.]([a-zA-Z0-9\\-_.]+)$")
        }

        private enum CodingKeys: String, CodingKey {
            case batchSize = "BatchSize"
            case consumerGroupID = "ConsumerGroupID"
            case credentials = "Credentials"
            case maximumBatchingWindowInSeconds = "MaximumBatchingWindowInSeconds"
            case startingPosition = "StartingPosition"
            case topicName = "TopicName"
        }
    }

    public struct PipeSourceParameters: AWSEncodableShape & AWSDecodableShape {
        /// The parameters for using an Active MQ broker as a source.
        public let activeMQBrokerParameters: PipeSourceActiveMQBrokerParameters?
        /// The parameters for using a DynamoDB stream as a source.
        public let dynamoDBStreamParameters: PipeSourceDynamoDBStreamParameters?
        /// The collection of event patterns used to filter events. To remove a filter, specify a FilterCriteria object with an empty array of Filter objects. For more information, see Events and Event Patterns in the Amazon EventBridge User Guide.
        public let filterCriteria: FilterCriteria?
        /// The parameters for using a Kinesis stream as a source.
        public let kinesisStreamParameters: PipeSourceKinesisStreamParameters?
        /// The parameters for using an MSK stream as a source.
        public let managedStreamingKafkaParameters: PipeSourceManagedStreamingKafkaParameters?
        /// The parameters for using a Rabbit MQ broker as a source.
        public let rabbitMQBrokerParameters: PipeSourceRabbitMQBrokerParameters?
        /// The parameters for using a self-managed Apache Kafka stream as a source. A self managed cluster refers to any Apache Kafka cluster not hosted by Amazon Web Services. This includes both clusters you manage yourself, as well as those hosted by a third-party provider, such as Confluent Cloud, CloudKarafka, or Redpanda. For more information, see Apache Kafka streams as a source in the Amazon EventBridge User Guide.
        public let selfManagedKafkaParameters: PipeSourceSelfManagedKafkaParameters?
        /// The parameters for using a Amazon SQS stream as a source.
        public let sqsQueueParameters: PipeSourceSqsQueueParameters?

        @inlinable
        public init(activeMQBrokerParameters: PipeSourceActiveMQBrokerParameters? = nil, dynamoDBStreamParameters: PipeSourceDynamoDBStreamParameters? = nil, filterCriteria: FilterCriteria? = nil, kinesisStreamParameters: PipeSourceKinesisStreamParameters? = nil, managedStreamingKafkaParameters: PipeSourceManagedStreamingKafkaParameters? = nil, rabbitMQBrokerParameters: PipeSourceRabbitMQBrokerParameters? = nil, selfManagedKafkaParameters: PipeSourceSelfManagedKafkaParameters? = nil, sqsQueueParameters: PipeSourceSqsQueueParameters? = nil) {
            self.activeMQBrokerParameters = activeMQBrokerParameters
            self.dynamoDBStreamParameters = dynamoDBStreamParameters
            self.filterCriteria = filterCriteria
            self.kinesisStreamParameters = kinesisStreamParameters
            self.managedStreamingKafkaParameters = managedStreamingKafkaParameters
            self.rabbitMQBrokerParameters = rabbitMQBrokerParameters
            self.selfManagedKafkaParameters = selfManagedKafkaParameters
            self.sqsQueueParameters = sqsQueueParameters
        }

        public func validate(name: String) throws {
            try self.activeMQBrokerParameters?.validate(name: "\(name).activeMQBrokerParameters")
            try self.dynamoDBStreamParameters?.validate(name: "\(name).dynamoDBStreamParameters")
            try self.filterCriteria?.validate(name: "\(name).filterCriteria")
            try self.kinesisStreamParameters?.validate(name: "\(name).kinesisStreamParameters")
            try self.managedStreamingKafkaParameters?.validate(name: "\(name).managedStreamingKafkaParameters")
            try self.rabbitMQBrokerParameters?.validate(name: "\(name).rabbitMQBrokerParameters")
            try self.selfManagedKafkaParameters?.validate(name: "\(name).selfManagedKafkaParameters")
            try self.sqsQueueParameters?.validate(name: "\(name).sqsQueueParameters")
        }

        private enum CodingKeys: String, CodingKey {
            case activeMQBrokerParameters = "ActiveMQBrokerParameters"
            case dynamoDBStreamParameters = "DynamoDBStreamParameters"
            case filterCriteria = "FilterCriteria"
            case kinesisStreamParameters = "KinesisStreamParameters"
            case managedStreamingKafkaParameters = "ManagedStreamingKafkaParameters"
            case rabbitMQBrokerParameters = "RabbitMQBrokerParameters"
            case selfManagedKafkaParameters = "SelfManagedKafkaParameters"
            case sqsQueueParameters = "SqsQueueParameters"
        }
    }

    public struct PipeSourceRabbitMQBrokerParameters: AWSEncodableShape & AWSDecodableShape {
        /// The maximum number of records to include in each batch.
        public let batchSize: Int?
        /// The credentials needed to access the resource.
        public let credentials: MQBrokerAccessCredentials
        /// The maximum length of a time to wait for events.
        public let maximumBatchingWindowInSeconds: Int?
        /// The name of the destination queue to consume.
        public let queueName: String
        /// The name of the virtual host associated with the source broker.
        public let virtualHost: String?

        @inlinable
        public init(batchSize: Int? = nil, credentials: MQBrokerAccessCredentials, maximumBatchingWindowInSeconds: Int? = nil, queueName: String, virtualHost: String? = nil) {
            self.batchSize = batchSize
            self.credentials = credentials
            self.maximumBatchingWindowInSeconds = maximumBatchingWindowInSeconds
            self.queueName = queueName
            self.virtualHost = virtualHost
        }

        public func validate(name: String) throws {
            try self.validate(self.batchSize, name: "batchSize", parent: name, max: 10000)
            try self.validate(self.batchSize, name: "batchSize", parent: name, min: 1)
            try self.credentials.validate(name: "\(name).credentials")
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, max: 300)
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, min: 0)
            try self.validate(self.queueName, name: "queueName", parent: name, max: 1000)
            try self.validate(self.queueName, name: "queueName", parent: name, min: 1)
            try self.validate(self.queueName, name: "queueName", parent: name, pattern: "^[\\s\\S]*$")
            try self.validate(self.virtualHost, name: "virtualHost", parent: name, max: 200)
            try self.validate(self.virtualHost, name: "virtualHost", parent: name, min: 1)
            try self.validate(self.virtualHost, name: "virtualHost", parent: name, pattern: "^[a-zA-Z0-9-\\/*:_+=.@-]*$")
        }

        private enum CodingKeys: String, CodingKey {
            case batchSize = "BatchSize"
            case credentials = "Credentials"
            case maximumBatchingWindowInSeconds = "MaximumBatchingWindowInSeconds"
            case queueName = "QueueName"
            case virtualHost = "VirtualHost"
        }
    }

    public struct PipeSourceSelfManagedKafkaParameters: AWSEncodableShape & AWSDecodableShape {
        /// An array of server URLs.
        public let additionalBootstrapServers: [String]?
        /// The maximum number of records to include in each batch.
        public let batchSize: Int?
        /// The name of the destination queue to consume.
        public let consumerGroupID: String?
        /// The credentials needed to access the resource.
        public let credentials: SelfManagedKafkaAccessConfigurationCredentials?
        /// The maximum length of a time to wait for events.
        public let maximumBatchingWindowInSeconds: Int?
        /// The ARN of the Secrets Manager secret used for certification.
        public let serverRootCaCertificate: String?
        /// The position in a stream from which to start reading.
        public let startingPosition: SelfManagedKafkaStartPosition?
        /// The name of the topic that the pipe will read from.
        public let topicName: String
        /// This structure specifies the VPC subnets and security groups for the stream, and whether a public IP address is to be used.
        public let vpc: SelfManagedKafkaAccessConfigurationVpc?

        @inlinable
        public init(additionalBootstrapServers: [String]? = nil, batchSize: Int? = nil, consumerGroupID: String? = nil, credentials: SelfManagedKafkaAccessConfigurationCredentials? = nil, maximumBatchingWindowInSeconds: Int? = nil, serverRootCaCertificate: String? = nil, startingPosition: SelfManagedKafkaStartPosition? = nil, topicName: String, vpc: SelfManagedKafkaAccessConfigurationVpc? = nil) {
            self.additionalBootstrapServers = additionalBootstrapServers
            self.batchSize = batchSize
            self.consumerGroupID = consumerGroupID
            self.credentials = credentials
            self.maximumBatchingWindowInSeconds = maximumBatchingWindowInSeconds
            self.serverRootCaCertificate = serverRootCaCertificate
            self.startingPosition = startingPosition
            self.topicName = topicName
            self.vpc = vpc
        }

        public func validate(name: String) throws {
            try self.additionalBootstrapServers?.forEach {
                try validate($0, name: "additionalBootstrapServers[]", parent: name, max: 300)
                try validate($0, name: "additionalBootstrapServers[]", parent: name, min: 1)
                try validate($0, name: "additionalBootstrapServers[]", parent: name, pattern: "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\\-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9\\-]*[A-Za-z0-9]):[0-9]{1,5}$")
            }
            try self.validate(self.additionalBootstrapServers, name: "additionalBootstrapServers", parent: name, max: 2)
            try self.validate(self.batchSize, name: "batchSize", parent: name, max: 10000)
            try self.validate(self.batchSize, name: "batchSize", parent: name, min: 1)
            try self.validate(self.consumerGroupID, name: "consumerGroupID", parent: name, max: 200)
            try self.validate(self.consumerGroupID, name: "consumerGroupID", parent: name, min: 1)
            try self.validate(self.consumerGroupID, name: "consumerGroupID", parent: name, pattern: "^[a-zA-Z0-9-\\/*:_+=.@-]*$")
            try self.credentials?.validate(name: "\(name).credentials")
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, max: 300)
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, min: 0)
            try self.validate(self.serverRootCaCertificate, name: "serverRootCaCertificate", parent: name, max: 1600)
            try self.validate(self.serverRootCaCertificate, name: "serverRootCaCertificate", parent: name, min: 1)
            try self.validate(self.serverRootCaCertificate, name: "serverRootCaCertificate", parent: name, pattern: "^(^arn:aws([a-z]|\\-)*:secretsmanager:([a-z]{2,4}((-gov)|(-de)|(-iso([a-z]?)))?-[a-z]+(-\\d{1})?):(\\d{12}):secret:.+)$")
            try self.validate(self.topicName, name: "topicName", parent: name, max: 249)
            try self.validate(self.topicName, name: "topicName", parent: name, min: 1)
            try self.validate(self.topicName, name: "topicName", parent: name, pattern: "^[^.]([a-zA-Z0-9\\-_.]+)$")
            try self.vpc?.validate(name: "\(name).vpc")
        }

        private enum CodingKeys: String, CodingKey {
            case additionalBootstrapServers = "AdditionalBootstrapServers"
            case batchSize = "BatchSize"
            case consumerGroupID = "ConsumerGroupID"
            case credentials = "Credentials"
            case maximumBatchingWindowInSeconds = "MaximumBatchingWindowInSeconds"
            case serverRootCaCertificate = "ServerRootCaCertificate"
            case startingPosition = "StartingPosition"
            case topicName = "TopicName"
            case vpc = "Vpc"
        }
    }

    public struct PipeSourceSqsQueueParameters: AWSEncodableShape & AWSDecodableShape {
        /// The maximum number of records to include in each batch.
        public let batchSize: Int?
        /// The maximum length of a time to wait for events.
        public let maximumBatchingWindowInSeconds: Int?

        @inlinable
        public init(batchSize: Int? = nil, maximumBatchingWindowInSeconds: Int? = nil) {
            self.batchSize = batchSize
            self.maximumBatchingWindowInSeconds = maximumBatchingWindowInSeconds
        }

        public func validate(name: String) throws {
            try self.validate(self.batchSize, name: "batchSize", parent: name, max: 10000)
            try self.validate(self.batchSize, name: "batchSize", parent: name, min: 1)
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, max: 300)
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, min: 0)
        }

        private enum CodingKeys: String, CodingKey {
            case batchSize = "BatchSize"
            case maximumBatchingWindowInSeconds = "MaximumBatchingWindowInSeconds"
        }
    }

    public struct PipeTargetBatchJobParameters: AWSEncodableShape & AWSDecodableShape {
        /// The array properties for the submitted job, such as the size of the array. The array size can be between 2 and 10,000.  If you specify array properties for a job, it becomes an array job. This parameter is used only if the target is an Batch job.
        public let arrayProperties: BatchArrayProperties?
        /// The overrides that are sent to a container.
        public let containerOverrides: BatchContainerOverrides?
        /// A list of dependencies for the job. A job can depend upon a maximum of 20 jobs. You can specify a SEQUENTIAL type dependency without specifying a job ID for array jobs so that each child array job completes sequentially, starting at index 0. You can also specify an N_TO_N type dependency with a job ID for array jobs. In that case, each index child of this job must wait for the corresponding index child of each dependency to complete before it can begin.
        public let dependsOn: [BatchJobDependency]?
        /// The job definition used by this job. This value can be one of name, name:revision, or the Amazon Resource Name (ARN) for the job definition. If name is specified without a revision then the latest active revision is used.
        public let jobDefinition: String
        /// The name of the job. It can be up to 128 letters long. The first character must be alphanumeric, can contain uppercase and lowercase letters, numbers, hyphens (-), and underscores (_).
        public let jobName: String
        /// Additional parameters passed to the job that replace parameter substitution placeholders that are set in the job definition. Parameters are specified as a key and value pair mapping. Parameters included here override any corresponding parameter defaults from the job definition.
        public let parameters: [String: String]?
        /// The retry strategy to use for failed jobs. When a retry strategy is specified here, it overrides the retry strategy defined in the job definition.
        public let retryStrategy: BatchRetryStrategy?

        @inlinable
        public init(arrayProperties: BatchArrayProperties? = nil, containerOverrides: BatchContainerOverrides? = nil, dependsOn: [BatchJobDependency]? = nil, jobDefinition: String, jobName: String, parameters: [String: String]? = nil, retryStrategy: BatchRetryStrategy? = nil) {
            self.arrayProperties = arrayProperties
            self.containerOverrides = containerOverrides
            self.dependsOn = dependsOn
            self.jobDefinition = jobDefinition
            self.jobName = jobName
            self.parameters = parameters
            self.retryStrategy = retryStrategy
        }

        public func validate(name: String) throws {
            try self.arrayProperties?.validate(name: "\(name).arrayProperties")
            try self.validate(self.dependsOn, name: "dependsOn", parent: name, max: 20)
            try self.retryStrategy?.validate(name: "\(name).retryStrategy")
        }

        private enum CodingKeys: String, CodingKey {
            case arrayProperties = "ArrayProperties"
            case containerOverrides = "ContainerOverrides"
            case dependsOn = "DependsOn"
            case jobDefinition = "JobDefinition"
            case jobName = "JobName"
            case parameters = "Parameters"
            case retryStrategy = "RetryStrategy"
        }
    }

    public struct PipeTargetCloudWatchLogsParameters: AWSEncodableShape & AWSDecodableShape {
        /// The name of the log stream.
        public let logStreamName: String?
        /// The time the event occurred, expressed as the number of milliseconds after Jan 1, 1970 00:00:00 UTC.
        public let timestamp: String?

        @inlinable
        public init(logStreamName: String? = nil, timestamp: String? = nil) {
            self.logStreamName = logStreamName
            self.timestamp = timestamp
        }

        public func validate(name: String) throws {
            try self.validate(self.logStreamName, name: "logStreamName", parent: name, max: 256)
            try self.validate(self.logStreamName, name: "logStreamName", parent: name, min: 1)
            try self.validate(self.timestamp, name: "timestamp", parent: name, max: 256)
            try self.validate(self.timestamp, name: "timestamp", parent: name, min: 1)
            try self.validate(self.timestamp, name: "timestamp", parent: name, pattern: "^\\$(\\.[\\w/_-]+(\\[(\\d+|\\*)\\])*)*$")
        }

        private enum CodingKeys: String, CodingKey {
            case logStreamName = "LogStreamName"
            case timestamp = "Timestamp"
        }
    }

    public struct PipeTargetEcsTaskParameters: AWSEncodableShape & AWSDecodableShape {
        /// The capacity provider strategy to use for the task. If a capacityProviderStrategy is specified, the launchType parameter must be omitted. If no capacityProviderStrategy or launchType is specified, the defaultCapacityProviderStrategy for the cluster is used.
        public let capacityProviderStrategy: [CapacityProviderStrategyItem]?
        /// Specifies whether to enable Amazon ECS managed tags for the task. For more information, see Tagging Your Amazon ECS Resources in the Amazon Elastic Container Service Developer Guide.
        public let enableECSManagedTags: Bool?
        /// Whether or not to enable the execute command functionality for the containers in this task. If true, this enables execute command functionality on all containers in the task.
        public let enableExecuteCommand: Bool?
        /// Specifies an Amazon ECS task group for the task. The maximum length is 255 characters.
        public let group: String?
        /// Specifies the launch type on which your task is running. The launch type that you specify here must match one of the launch type (compatibilities) of the target task. The FARGATE value is supported only in the Regions where Fargate with Amazon ECS is supported. For more information, see Fargate on Amazon ECS in the Amazon Elastic Container Service Developer Guide.
        public let launchType: LaunchType?
        /// Use this structure if the Amazon ECS task uses the awsvpc network mode. This structure specifies the VPC subnets and security groups associated with the task, and whether a public IP address is to be used. This structure is required if LaunchType is FARGATE because the awsvpc mode is required for Fargate tasks. If you specify NetworkConfiguration when the target ECS task does not use the awsvpc network mode, the task fails.
        public let networkConfiguration: NetworkConfiguration?
        /// The overrides that are associated with a task.
        public let overrides: EcsTaskOverride?
        /// An array of placement constraint objects to use for the task. You can specify up to 10 constraints per task (including constraints in the task definition and those specified at runtime).
        public let placementConstraints: [PlacementConstraint]?
        /// The placement strategy objects to use for the task. You can specify a maximum of five strategy rules per task.
        public let placementStrategy: [PlacementStrategy]?
        /// Specifies the platform version for the task. Specify only the numeric portion of the platform version, such as 1.1.0. This structure is used only if LaunchType is FARGATE. For more information about valid platform versions, see Fargate Platform Versions in the Amazon Elastic Container Service Developer Guide.
        public let platformVersion: String?
        /// Specifies whether to propagate the tags from the task definition to the task. If no value is specified, the tags are not propagated. Tags can only be propagated to the task during task creation. To add tags to a task after task creation, use the TagResource API action.
        public let propagateTags: PropagateTags?
        /// The reference ID to use for the task.
        public let referenceId: String?
        /// The metadata that you apply to the task to help you categorize and organize them. Each tag consists of a key and an optional value, both of which you define. To learn more, see RunTask in the Amazon ECS API Reference.
        public let tags: [Tag]?
        /// The number of tasks to create based on TaskDefinition. The default is 1.
        public let taskCount: Int?
        /// The ARN of the task definition to use if the event target is an Amazon ECS task.
        public let taskDefinitionArn: String

        @inlinable
        public init(capacityProviderStrategy: [CapacityProviderStrategyItem]? = nil, enableECSManagedTags: Bool? = nil, enableExecuteCommand: Bool? = nil, group: String? = nil, launchType: LaunchType? = nil, networkConfiguration: NetworkConfiguration? = nil, overrides: EcsTaskOverride? = nil, placementConstraints: [PlacementConstraint]? = nil, placementStrategy: [PlacementStrategy]? = nil, platformVersion: String? = nil, propagateTags: PropagateTags? = nil, referenceId: String? = nil, tags: [Tag]? = nil, taskCount: Int? = nil, taskDefinitionArn: String) {
            self.capacityProviderStrategy = capacityProviderStrategy
            self.enableECSManagedTags = enableECSManagedTags
            self.enableExecuteCommand = enableExecuteCommand
            self.group = group
            self.launchType = launchType
            self.networkConfiguration = networkConfiguration
            self.overrides = overrides
            self.placementConstraints = placementConstraints
            self.placementStrategy = placementStrategy
            self.platformVersion = platformVersion
            self.propagateTags = propagateTags
            self.referenceId = referenceId
            self.tags = tags
            self.taskCount = taskCount
            self.taskDefinitionArn = taskDefinitionArn
        }

        public func validate(name: String) throws {
            try self.capacityProviderStrategy?.forEach {
                try $0.validate(name: "\(name).capacityProviderStrategy[]")
            }
            try self.validate(self.capacityProviderStrategy, name: "capacityProviderStrategy", parent: name, max: 6)
            try self.networkConfiguration?.validate(name: "\(name).networkConfiguration")
            try self.overrides?.validate(name: "\(name).overrides")
            try self.placementConstraints?.forEach {
                try $0.validate(name: "\(name).placementConstraints[]")
            }
            try self.validate(self.placementConstraints, name: "placementConstraints", parent: name, max: 10)
            try self.placementStrategy?.forEach {
                try $0.validate(name: "\(name).placementStrategy[]")
            }
            try self.validate(self.placementStrategy, name: "placementStrategy", parent: name, max: 5)
            try self.validate(self.referenceId, name: "referenceId", parent: name, max: 1024)
            try self.tags?.forEach {
                try $0.validate(name: "\(name).tags[]")
            }
            try self.validate(self.taskCount, name: "taskCount", parent: name, min: 1)
            try self.validate(self.taskDefinitionArn, name: "taskDefinitionArn", parent: name, max: 1600)
            try self.validate(self.taskDefinitionArn, name: "taskDefinitionArn", parent: name, min: 1)
            try self.validate(self.taskDefinitionArn, name: "taskDefinitionArn", parent: name, pattern: "^arn:(aws[a-zA-Z0-9-]*):([a-zA-Z0-9\\-]+):([a-z]{2,4}((-gov)|(-de)|(-iso([a-z]?)))?-[a-z]+(-\\d{1})?)?:(\\d{12})?:(.+)|(\\$(\\.[\\w/_-]+(\\[(\\d+|\\*)\\])*)*)$")
        }

        private enum CodingKeys: String, CodingKey {
            case capacityProviderStrategy = "CapacityProviderStrategy"
            case enableECSManagedTags = "EnableECSManagedTags"
            case enableExecuteCommand = "EnableExecuteCommand"
            case group = "Group"
            case launchType = "LaunchType"
            case networkConfiguration = "NetworkConfiguration"
            case overrides = "Overrides"
            case placementConstraints = "PlacementConstraints"
            case placementStrategy = "PlacementStrategy"
            case platformVersion = "PlatformVersion"
            case propagateTags = "PropagateTags"
            case referenceId = "ReferenceId"
            case tags = "Tags"
            case taskCount = "TaskCount"
            case taskDefinitionArn = "TaskDefinitionArn"
        }
    }

    public struct PipeTargetEventBridgeEventBusParameters: AWSEncodableShape & AWSDecodableShape {
        /// A free-form string, with a maximum of 128 characters, used to decide what fields to expect in the event detail.
        public let detailType: String?
        /// The URL subdomain of the endpoint. For example, if the URL for Endpoint is https://abcde.veo.endpoints.event.amazonaws.com, then the EndpointId is abcde.veo.
        public let endpointId: String?
        /// Amazon Web Services resources, identified by Amazon Resource Name (ARN), which the event primarily concerns. Any number, including zero, may be present.
        public let resources: [String]?
        /// The source of the event.
        public let source: String?
        /// The time stamp of the event, per RFC3339. If no time stamp is provided, the time stamp of the PutEvents call is used.
        public let time: String?

        @inlinable
        public init(detailType: String? = nil, endpointId: String? = nil, resources: [String]? = nil, source: String? = nil, time: String? = nil) {
            self.detailType = detailType
            self.endpointId = endpointId
            self.resources = resources
            self.source = source
            self.time = time
        }

        public func validate(name: String) throws {
            try self.validate(self.detailType, name: "detailType", parent: name, max: 128)
            try self.validate(self.detailType, name: "detailType", parent: name, min: 1)
            try self.validate(self.endpointId, name: "endpointId", parent: name, max: 50)
            try self.validate(self.endpointId, name: "endpointId", parent: name, min: 1)
            try self.validate(self.endpointId, name: "endpointId", parent: name, pattern: "^[A-Za-z0-9\\-]+[\\.][A-Za-z0-9\\-]+$")
            try self.resources?.forEach {
                try validate($0, name: "resources[]", parent: name, max: 1600)
                try validate($0, name: "resources[]", parent: name, min: 1)
                try validate($0, name: "resources[]", parent: name, pattern: "^arn:(aws[a-zA-Z0-9-]*):([a-zA-Z0-9\\-]+):([a-z]{2,4}((-gov)|(-de)|(-iso([a-z]?)))?-[a-z]+(-\\d{1})?)?:(\\d{12})?:(.+)|(\\$(\\.[\\w/_-]+(\\[(\\d+|\\*)\\])*)*)$")
            }
            try self.validate(self.resources, name: "resources", parent: name, max: 10)
            try self.validate(self.source, name: "source", parent: name, max: 256)
            try self.validate(self.source, name: "source", parent: name, min: 1)
            try self.validate(self.source, name: "source", parent: name, pattern: "(?=[/\\.\\-_A-Za-z0-9]+)((?!aws\\.).*)|(\\$(\\.[\\w/_-]+(\\[(\\d+|\\*)\\])*)*)")
            try self.validate(self.time, name: "time", parent: name, max: 256)
            try self.validate(self.time, name: "time", parent: name, min: 1)
            try self.validate(self.time, name: "time", parent: name, pattern: "^\\$(\\.[\\w/_-]+(\\[(\\d+|\\*)\\])*)*$")
        }

        private enum CodingKeys: String, CodingKey {
            case detailType = "DetailType"
            case endpointId = "EndpointId"
            case resources = "Resources"
            case source = "Source"
            case time = "Time"
        }
    }

    public struct PipeTargetHttpParameters: AWSEncodableShape & AWSDecodableShape {
        /// The headers that need to be sent as part of request invoking the API Gateway REST API or EventBridge ApiDestination.
        public let headerParameters: [String: String]?
        /// The path parameter values to be used to populate API Gateway REST API or EventBridge ApiDestination path wildcards ("*").
        public let pathParameterValues: [String]?
        /// The query string keys/values that need to be sent as part of request invoking the API Gateway REST API or EventBridge ApiDestination.
        public let queryStringParameters: [String: String]?

        @inlinable
        public init(headerParameters: [String: String]? = nil, pathParameterValues: [String]? = nil, queryStringParameters: [String: String]? = nil) {
            self.headerParameters = headerParameters
            self.pathParameterValues = pathParameterValues
            self.queryStringParameters = queryStringParameters
        }

        public func validate(name: String) throws {
            try self.headerParameters?.forEach {
                try validate($0.key, name: "headerParameters.key", parent: name, max: 512)
                try validate($0.key, name: "headerParameters.key", parent: name, pattern: "^[!#$%&'*+-.^_`|~0-9a-zA-Z]+|(\\$(\\.[\\w/_-]+(\\[(\\d+|\\*)\\])*)*)$")
                try validate($0.value, name: "headerParameters[\"\($0.key)\"]", parent: name, max: 512)
                try validate($0.value, name: "headerParameters[\"\($0.key)\"]", parent: name, pattern: "^[ \\t]*[\\x20-\\x7E]+([ \\t]+[\\x20-\\x7E]+)*[ \\t]*|(\\$(\\.[\\w/_-]+(\\[(\\d+|\\*)\\])*)*)$")
            }
            try self.pathParameterValues?.forEach {
                try validate($0, name: "pathParameterValues[]", parent: name, pattern: "^(?!\\s*$).+|(\\$(\\.[\\w/_-]+(\\[(\\d+|\\*)\\])*)*)$")
            }
            try self.queryStringParameters?.forEach {
                try validate($0.key, name: "queryStringParameters.key", parent: name, max: 512)
                try validate($0.key, name: "queryStringParameters.key", parent: name, pattern: "^[^\\x00-\\x1F\\x7F]+|(\\$(\\.[\\w/_-]+(\\[(\\d+|\\*)\\])*)*)$")
                try validate($0.value, name: "queryStringParameters[\"\($0.key)\"]", parent: name, max: 512)
                try validate($0.value, name: "queryStringParameters[\"\($0.key)\"]", parent: name, pattern: "^[^\\x00-\\x09\\x0B\\x0C\\x0E-\\x1F\\x7F]+|(\\$(\\.[\\w/_-]+(\\[(\\d+|\\*)\\])*)*)$")
            }
        }

        private enum CodingKeys: String, CodingKey {
            case headerParameters = "HeaderParameters"
            case pathParameterValues = "PathParameterValues"
            case queryStringParameters = "QueryStringParameters"
        }
    }

    public struct PipeTargetKinesisStreamParameters: AWSEncodableShape & AWSDecodableShape {
        /// Determines which shard in the stream the data record is assigned to. Partition keys are Unicode strings with a maximum length limit of 256 characters for each key. Amazon Kinesis Data Streams uses the partition key as input to a hash function that maps the partition key and associated data to a specific shard. Specifically, an MD5 hash function is used to map partition keys to 128-bit integer values and to map associated data records to shards. As a result of this hashing mechanism, all data records with the same partition key map to the same shard within the stream.
        public let partitionKey: String

        @inlinable
        public init(partitionKey: String) {
            self.partitionKey = partitionKey
        }

        public func validate(name: String) throws {
            try self.validate(self.partitionKey, name: "partitionKey", parent: name, max: 256)
        }

        private enum CodingKeys: String, CodingKey {
            case partitionKey = "PartitionKey"
        }
    }

    public struct PipeTargetLambdaFunctionParameters: AWSEncodableShape & AWSDecodableShape {
        /// Specify whether to invoke the function synchronously or asynchronously.    REQUEST_RESPONSE (default) - Invoke synchronously. This corresponds to the RequestResponse option in the InvocationType parameter for the Lambda Invoke API.    FIRE_AND_FORGET - Invoke asynchronously. This corresponds to the Event option in the InvocationType parameter for the Lambda Invoke API.   For more information, see Invocation types in the Amazon EventBridge User Guide.
        public let invocationType: PipeTargetInvocationType?

        @inlinable
        public init(invocationType: PipeTargetInvocationType? = nil) {
            self.invocationType = invocationType
        }

        private enum CodingKeys: String, CodingKey {
            case invocationType = "InvocationType"
        }
    }

    public struct PipeTargetParameters: AWSEncodableShape & AWSDecodableShape {
        /// The parameters for using an Batch job as a target.
        public let batchJobParameters: PipeTargetBatchJobParameters?
        /// The parameters for using an CloudWatch Logs log stream as a target.
        public let cloudWatchLogsParameters: PipeTargetCloudWatchLogsParameters?
        /// The parameters for using an Amazon ECS task as a target.
        public let ecsTaskParameters: PipeTargetEcsTaskParameters?
        /// The parameters for using an EventBridge event bus as a target.
        public let eventBridgeEventBusParameters: PipeTargetEventBridgeEventBusParameters?
        /// These are custom parameter to be used when the target is an API Gateway REST APIs or EventBridge ApiDestinations.
        public let httpParameters: PipeTargetHttpParameters?
        /// Valid JSON text passed to the target. In this case, nothing from the event itself is passed to the target. For more information, see The JavaScript Object Notation (JSON) Data Interchange Format. To remove an input template, specify an empty string.
        public let inputTemplate: String?
        /// The parameters for using a Kinesis stream as a target.
        public let kinesisStreamParameters: PipeTargetKinesisStreamParameters?
        /// The parameters for using a Lambda function as a target.
        public let lambdaFunctionParameters: PipeTargetLambdaFunctionParameters?
        /// These are custom parameters to be used when the target is a Amazon Redshift cluster to invoke the Amazon Redshift Data API BatchExecuteStatement.
        public let redshiftDataParameters: PipeTargetRedshiftDataParameters?
        /// The parameters for using a SageMaker pipeline as a target.
        public let sageMakerPipelineParameters: PipeTargetSageMakerPipelineParameters?
        /// The parameters for using a Amazon SQS stream as a target.
        public let sqsQueueParameters: PipeTargetSqsQueueParameters?
        /// The parameters for using a Step Functions state machine as a target.
        public let stepFunctionStateMachineParameters: PipeTargetStateMachineParameters?
        /// The parameters for using a Timestream for LiveAnalytics table as a target.
        public let timestreamParameters: PipeTargetTimestreamParameters?

        @inlinable
        public init(batchJobParameters: PipeTargetBatchJobParameters? = nil, cloudWatchLogsParameters: PipeTargetCloudWatchLogsParameters? = nil, ecsTaskParameters: PipeTargetEcsTaskParameters? = nil, eventBridgeEventBusParameters: PipeTargetEventBridgeEventBusParameters? = nil, httpParameters: PipeTargetHttpParameters? = nil, inputTemplate: String? = nil, kinesisStreamParameters: PipeTargetKinesisStreamParameters? = nil, lambdaFunctionParameters: PipeTargetLambdaFunctionParameters? = nil, redshiftDataParameters: PipeTargetRedshiftDataParameters? = nil, sageMakerPipelineParameters: PipeTargetSageMakerPipelineParameters? = nil, sqsQueueParameters: PipeTargetSqsQueueParameters? = nil, stepFunctionStateMachineParameters: PipeTargetStateMachineParameters? = nil, timestreamParameters: PipeTargetTimestreamParameters? = nil) {
            self.batchJobParameters = batchJobParameters
            self.cloudWatchLogsParameters = cloudWatchLogsParameters
            self.ecsTaskParameters = ecsTaskParameters
            self.eventBridgeEventBusParameters = eventBridgeEventBusParameters
            self.httpParameters = httpParameters
            self.inputTemplate = inputTemplate
            self.kinesisStreamParameters = kinesisStreamParameters
            self.lambdaFunctionParameters = lambdaFunctionParameters
            self.redshiftDataParameters = redshiftDataParameters
            self.sageMakerPipelineParameters = sageMakerPipelineParameters
            self.sqsQueueParameters = sqsQueueParameters
            self.stepFunctionStateMachineParameters = stepFunctionStateMachineParameters
            self.timestreamParameters = timestreamParameters
        }

        public func validate(name: String) throws {
            try self.batchJobParameters?.validate(name: "\(name).batchJobParameters")
            try self.cloudWatchLogsParameters?.validate(name: "\(name).cloudWatchLogsParameters")
            try self.ecsTaskParameters?.validate(name: "\(name).ecsTaskParameters")
            try self.eventBridgeEventBusParameters?.validate(name: "\(name).eventBridgeEventBusParameters")
            try self.httpParameters?.validate(name: "\(name).httpParameters")
            try self.validate(self.inputTemplate, name: "inputTemplate", parent: name, max: 8192)
            try self.kinesisStreamParameters?.validate(name: "\(name).kinesisStreamParameters")
            try self.redshiftDataParameters?.validate(name: "\(name).redshiftDataParameters")
            try self.sageMakerPipelineParameters?.validate(name: "\(name).sageMakerPipelineParameters")
            try self.sqsQueueParameters?.validate(name: "\(name).sqsQueueParameters")
            try self.timestreamParameters?.validate(name: "\(name).timestreamParameters")
        }

        private enum CodingKeys: String, CodingKey {
            case batchJobParameters = "BatchJobParameters"
            case cloudWatchLogsParameters = "CloudWatchLogsParameters"
            case ecsTaskParameters = "EcsTaskParameters"
            case eventBridgeEventBusParameters = "EventBridgeEventBusParameters"
            case httpParameters = "HttpParameters"
            case inputTemplate = "InputTemplate"
            case kinesisStreamParameters = "KinesisStreamParameters"
            case lambdaFunctionParameters = "LambdaFunctionParameters"
            case redshiftDataParameters = "RedshiftDataParameters"
            case sageMakerPipelineParameters = "SageMakerPipelineParameters"
            case sqsQueueParameters = "SqsQueueParameters"
            case stepFunctionStateMachineParameters = "StepFunctionStateMachineParameters"
            case timestreamParameters = "TimestreamParameters"
        }
    }

    public struct PipeTargetRedshiftDataParameters: AWSEncodableShape & AWSDecodableShape {
        /// The name of the database. Required when authenticating using temporary credentials.
        public let database: String
        /// The database user name. Required when authenticating using temporary credentials.
        public let dbUser: String?
        /// The name or ARN of the secret that enables access to the database. Required when authenticating using Secrets Manager.
        public let secretManagerArn: String?
        /// The SQL statement text to run.
        public let sqls: [String]
        /// The name of the SQL statement. You can name the SQL statement when you create it to identify the query.
        public let statementName: String?
        /// Indicates whether to send an event back to EventBridge after the SQL statement runs.
        public let withEvent: Bool?

        @inlinable
        public init(database: String, dbUser: String? = nil, secretManagerArn: String? = nil, sqls: [String], statementName: String? = nil, withEvent: Bool? = nil) {
            self.database = database
            self.dbUser = dbUser
            self.secretManagerArn = secretManagerArn
            self.sqls = sqls
            self.statementName = statementName
            self.withEvent = withEvent
        }

        public func validate(name: String) throws {
            try self.validate(self.database, name: "database", parent: name, max: 64)
            try self.validate(self.database, name: "database", parent: name, min: 1)
            try self.validate(self.dbUser, name: "dbUser", parent: name, max: 128)
            try self.validate(self.dbUser, name: "dbUser", parent: name, min: 1)
            try self.validate(self.secretManagerArn, name: "secretManagerArn", parent: name, max: 1600)
            try self.validate(self.secretManagerArn, name: "secretManagerArn", parent: name, min: 1)
            try self.validate(self.secretManagerArn, name: "secretManagerArn", parent: name, pattern: "^(^arn:aws([a-z]|\\-)*:secretsmanager:([a-z]{2,4}((-gov)|(-de)|(-iso([a-z]?)))?-[a-z]+(-\\d{1})?):(\\d{12}):secret:.+)|(\\$(\\.[\\w/_-]+(\\[(\\d+|\\*)\\])*)*)$")
            try self.sqls.forEach {
                try validate($0, name: "sqls[]", parent: name, max: 100000)
                try validate($0, name: "sqls[]", parent: name, min: 1)
            }
            try self.validate(self.sqls, name: "sqls", parent: name, max: 40)
            try self.validate(self.sqls, name: "sqls", parent: name, min: 1)
            try self.validate(self.statementName, name: "statementName", parent: name, max: 500)
            try self.validate(self.statementName, name: "statementName", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case database = "Database"
            case dbUser = "DbUser"
            case secretManagerArn = "SecretManagerArn"
            case sqls = "Sqls"
            case statementName = "StatementName"
            case withEvent = "WithEvent"
        }
    }

    public struct PipeTargetSageMakerPipelineParameters: AWSEncodableShape & AWSDecodableShape {
        /// List of Parameter names and values for SageMaker Model Building Pipeline execution.
        public let pipelineParameterList: [SageMakerPipelineParameter]?

        @inlinable
        public init(pipelineParameterList: [SageMakerPipelineParameter]? = nil) {
            self.pipelineParameterList = pipelineParameterList
        }

        public func validate(name: String) throws {
            try self.pipelineParameterList?.forEach {
                try $0.validate(name: "\(name).pipelineParameterList[]")
            }
            try self.validate(self.pipelineParameterList, name: "pipelineParameterList", parent: name, max: 200)
        }

        private enum CodingKeys: String, CodingKey {
            case pipelineParameterList = "PipelineParameterList"
        }
    }

    public struct PipeTargetSqsQueueParameters: AWSEncodableShape & AWSDecodableShape {
        /// This parameter applies only to FIFO (first-in-first-out) queues. The token used for deduplication of sent messages.
        public let messageDeduplicationId: String?
        /// The FIFO message group ID to use as the target.
        public let messageGroupId: String?

        @inlinable
        public init(messageDeduplicationId: String? = nil, messageGroupId: String? = nil) {
            self.messageDeduplicationId = messageDeduplicationId
            self.messageGroupId = messageGroupId
        }

        public func validate(name: String) throws {
            try self.validate(self.messageDeduplicationId, name: "messageDeduplicationId", parent: name, max: 100)
            try self.validate(self.messageGroupId, name: "messageGroupId", parent: name, max: 100)
        }

        private enum CodingKeys: String, CodingKey {
            case messageDeduplicationId = "MessageDeduplicationId"
            case messageGroupId = "MessageGroupId"
        }
    }

    public struct PipeTargetStateMachineParameters: AWSEncodableShape & AWSDecodableShape {
        /// Specify whether to invoke the Step Functions state machine synchronously or asynchronously.    REQUEST_RESPONSE (default) - Invoke synchronously. For more information, see StartSyncExecution in the Step Functions API Reference.   REQUEST_RESPONSE is not supported for STANDARD state machine workflows.     FIRE_AND_FORGET - Invoke asynchronously. For more information, see StartExecution in the Step Functions API Reference.   For more information, see Invocation types in the Amazon EventBridge User Guide.
        public let invocationType: PipeTargetInvocationType?

        @inlinable
        public init(invocationType: PipeTargetInvocationType? = nil) {
            self.invocationType = invocationType
        }

        private enum CodingKeys: String, CodingKey {
            case invocationType = "InvocationType"
        }
    }

    public struct PipeTargetTimestreamParameters: AWSEncodableShape & AWSDecodableShape {
        /// Map source data to dimensions in the target Timestream for LiveAnalytics table. For more information, see Amazon Timestream for LiveAnalytics concepts
        public let dimensionMappings: [DimensionMapping]
        /// The granularity of the time units used. Default is MILLISECONDS. Required if TimeFieldType is specified as EPOCH.
        public let epochTimeUnit: EpochTimeUnit?
        /// Maps multiple measures from the source event to the same record in the specified Timestream for LiveAnalytics table.
        public let multiMeasureMappings: [MultiMeasureMapping]?
        /// Mappings of single source data fields to individual records in the specified Timestream for LiveAnalytics table.
        public let singleMeasureMappings: [SingleMeasureMapping]?
        /// The type of time value used. The default is EPOCH.
        public let timeFieldType: TimeFieldType?
        /// How to format the timestamps. For example, yyyy-MM-dd'T'HH:mm:ss'Z'. Required if TimeFieldType is specified as TIMESTAMP_FORMAT.
        public let timestampFormat: String?
        /// Dynamic path to the source data field that represents the time value for your data.
        public let timeValue: String
        /// 64 bit version value or source data field that represents the version value for your data. Write requests with a higher version number will update the existing measure values of the record and version.  In cases where the measure value is the same, the version will still be updated.  Default value is 1.  Timestream for LiveAnalytics does not support updating partial measure values in a record. Write requests for duplicate data with a higher version number will update the existing measure value and version. In cases where the measure value is the same, Version will still be updated. Default value is 1.   Version must be 1 or greater, or you will receive a ValidationException error.
        public let versionValue: String

        @inlinable
        public init(dimensionMappings: [DimensionMapping], epochTimeUnit: EpochTimeUnit? = nil, multiMeasureMappings: [MultiMeasureMapping]? = nil, singleMeasureMappings: [SingleMeasureMapping]? = nil, timeFieldType: TimeFieldType? = nil, timestampFormat: String? = nil, timeValue: String, versionValue: String) {
            self.dimensionMappings = dimensionMappings
            self.epochTimeUnit = epochTimeUnit
            self.multiMeasureMappings = multiMeasureMappings
            self.singleMeasureMappings = singleMeasureMappings
            self.timeFieldType = timeFieldType
            self.timestampFormat = timestampFormat
            self.timeValue = timeValue
            self.versionValue = versionValue
        }

        public func validate(name: String) throws {
            try self.dimensionMappings.forEach {
                try $0.validate(name: "\(name).dimensionMappings[]")
            }
            try self.validate(self.dimensionMappings, name: "dimensionMappings", parent: name, max: 128)
            try self.validate(self.dimensionMappings, name: "dimensionMappings", parent: name, min: 1)
            try self.multiMeasureMappings?.forEach {
                try $0.validate(name: "\(name).multiMeasureMappings[]")
            }
            try self.validate(self.multiMeasureMappings, name: "multiMeasureMappings", parent: name, max: 1024)
            try self.singleMeasureMappings?.forEach {
                try $0.validate(name: "\(name).singleMeasureMappings[]")
            }
            try self.validate(self.singleMeasureMappings, name: "singleMeasureMappings", parent: name, max: 8192)
            try self.validate(self.timestampFormat, name: "timestampFormat", parent: name, max: 256)
            try self.validate(self.timestampFormat, name: "timestampFormat", parent: name, min: 1)
            try self.validate(self.timeValue, name: "timeValue", parent: name, max: 256)
            try self.validate(self.timeValue, name: "timeValue", parent: name, min: 1)
            try self.validate(self.versionValue, name: "versionValue", parent: name, max: 256)
            try self.validate(self.versionValue, name: "versionValue", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case dimensionMappings = "DimensionMappings"
            case epochTimeUnit = "EpochTimeUnit"
            case multiMeasureMappings = "MultiMeasureMappings"
            case singleMeasureMappings = "SingleMeasureMappings"
            case timeFieldType = "TimeFieldType"
            case timestampFormat = "TimestampFormat"
            case timeValue = "TimeValue"
            case versionValue = "VersionValue"
        }
    }

    public struct PlacementConstraint: AWSEncodableShape & AWSDecodableShape {
        /// A cluster query language expression to apply to the constraint. You cannot specify an expression if the constraint type is distinctInstance. To learn more, see Cluster Query Language in the Amazon Elastic Container Service Developer Guide.
        public let expression: String?
        /// The type of constraint. Use distinctInstance to ensure that each task in a particular group is running on a different container instance. Use memberOf to restrict the selection to a group of valid candidates.
        public let type: PlacementConstraintType?

        @inlinable
        public init(expression: String? = nil, type: PlacementConstraintType? = nil) {
            self.expression = expression
            self.type = type
        }

        public func validate(name: String) throws {
            try self.validate(self.expression, name: "expression", parent: name, max: 2000)
        }

        private enum CodingKeys: String, CodingKey {
            case expression = "expression"
            case type = "type"
        }
    }

    public struct PlacementStrategy: AWSEncodableShape & AWSDecodableShape {
        /// The field to apply the placement strategy against. For the spread placement strategy, valid values are instanceId (or host, which has the same effect), or any platform or custom attribute that is applied to a container instance, such as attribute:ecs.availability-zone. For the binpack placement strategy, valid values are cpu and memory. For the random placement strategy, this field is not used.
        public let field: String?
        /// The type of placement strategy. The random placement strategy randomly places tasks on available candidates. The spread placement strategy spreads placement across available candidates evenly based on the field parameter. The binpack strategy places tasks on available candidates that have the least available amount of the resource that is specified with the field parameter. For example, if you binpack on memory, a task is placed on the instance with the least amount of remaining memory (but still enough to run the task).
        public let type: PlacementStrategyType?

        @inlinable
        public init(field: String? = nil, type: PlacementStrategyType? = nil) {
            self.field = field
            self.type = type
        }

        public func validate(name: String) throws {
            try self.validate(self.field, name: "field", parent: name, max: 255)
        }

        private enum CodingKeys: String, CodingKey {
            case field = "field"
            case type = "type"
        }
    }

    public struct S3LogDestination: AWSDecodableShape {
        /// The name of the Amazon S3 bucket to which EventBridge delivers the log records for the pipe.
        public let bucketName: String?
        /// The Amazon Web Services account that owns the Amazon S3 bucket to which EventBridge delivers the log records for the pipe.
        public let bucketOwner: String?
        /// The format EventBridge uses for the log records. EventBridge currently only supports json formatting.
        public let outputFormat: S3OutputFormat?
        /// The prefix text with which to begin Amazon S3 log object names. For more information, see Organizing objects using prefixes in the Amazon Simple Storage Service User Guide.
        public let prefix: String?

        @inlinable
        public init(bucketName: String? = nil, bucketOwner: String? = nil, outputFormat: S3OutputFormat? = nil, prefix: String? = nil) {
            self.bucketName = bucketName
            self.bucketOwner = bucketOwner
            self.outputFormat = outputFormat
            self.prefix = prefix
        }

        private enum CodingKeys: String, CodingKey {
            case bucketName = "BucketName"
            case bucketOwner = "BucketOwner"
            case outputFormat = "OutputFormat"
            case prefix = "Prefix"
        }
    }

    public struct S3LogDestinationParameters: AWSEncodableShape {
        /// Specifies the name of the Amazon S3 bucket to which EventBridge delivers the log records for the pipe.
        public let bucketName: String
        /// Specifies the Amazon Web Services account that owns the Amazon S3 bucket to which EventBridge delivers the log records for the pipe.
        public let bucketOwner: String
        /// How EventBridge should format the log records. EventBridge currently only supports json formatting.
        public let outputFormat: S3OutputFormat?
        /// Specifies any prefix text with which to begin Amazon S3 log object names. You can use prefixes to organize the data that you store in Amazon S3 buckets. A prefix is a string of characters at the beginning of the object key name. A prefix can be any length, subject to the maximum length of the object key name (1,024 bytes). For more information, see Organizing objects using prefixes in the Amazon Simple Storage Service User Guide.
        public let prefix: String?

        @inlinable
        public init(bucketName: String, bucketOwner: String, outputFormat: S3OutputFormat? = nil, prefix: String? = nil) {
            self.bucketName = bucketName
            self.bucketOwner = bucketOwner
            self.outputFormat = outputFormat
            self.prefix = prefix
        }

        private enum CodingKeys: String, CodingKey {
            case bucketName = "BucketName"
            case bucketOwner = "BucketOwner"
            case outputFormat = "OutputFormat"
            case prefix = "Prefix"
        }
    }

    public struct SageMakerPipelineParameter: AWSEncodableShape & AWSDecodableShape {
        /// Name of parameter to start execution of a SageMaker Model Building Pipeline.
        public let name: String
        /// Value of parameter to start execution of a SageMaker Model Building Pipeline.
        public let value: String

        @inlinable
        public init(name: String, value: String) {
            self.name = name
            self.value = value
        }

        public func validate(name: String) throws {
            try self.validate(self.name, name: "name", parent: name, max: 256)
            try self.validate(self.name, name: "name", parent: name, min: 1)
            try self.validate(self.name, name: "name", parent: name, pattern: "^[a-zA-Z0-9](-*[a-zA-Z0-9])*|(\\$(\\.[\\w/_-]+(\\[(\\d+|\\*)\\])*)*)$")
            try self.validate(self.value, name: "value", parent: name, max: 1024)
        }

        private enum CodingKeys: String, CodingKey {
            case name = "Name"
            case value = "Value"
        }
    }

    public struct SelfManagedKafkaAccessConfigurationVpc: AWSEncodableShape & AWSDecodableShape {
        /// Specifies the security groups associated with the stream. These security groups must all be in the same VPC. You can specify as many as five security groups.
        public let securityGroup: [String]?
        /// Specifies the subnets associated with the stream. These subnets must all be in the same VPC. You can specify as many as 16 subnets.
        public let subnets: [String]?

        @inlinable
        public init(securityGroup: [String]? = nil, subnets: [String]? = nil) {
            self.securityGroup = securityGroup
            self.subnets = subnets
        }

        public func validate(name: String) throws {
            try self.securityGroup?.forEach {
                try validate($0, name: "securityGroup[]", parent: name, max: 1024)
                try validate($0, name: "securityGroup[]", parent: name, min: 1)
                try validate($0, name: "securityGroup[]", parent: name, pattern: "^sg-[0-9a-zA-Z]*$")
            }
            try self.validate(self.securityGroup, name: "securityGroup", parent: name, max: 5)
            try self.validate(self.securityGroup, name: "securityGroup", parent: name, min: 1)
            try self.subnets?.forEach {
                try validate($0, name: "subnets[]", parent: name, max: 1024)
                try validate($0, name: "subnets[]", parent: name, min: 1)
                try validate($0, name: "subnets[]", parent: name, pattern: "^subnet-[0-9a-z]*$")
            }
            try self.validate(self.subnets, name: "subnets", parent: name, max: 16)
            try self.validate(self.subnets, name: "subnets", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case securityGroup = "SecurityGroup"
            case subnets = "Subnets"
        }
    }

    public struct ServiceQuotaExceededException: AWSErrorShape {
        public let message: String
        /// The identifier of the quota that caused the exception.
        public let quotaCode: String
        /// The ID of the resource that caused the exception.
        public let resourceId: String
        /// The type of resource that caused the exception.
        public let resourceType: String
        /// The identifier of the service that caused the exception.
        public let serviceCode: String

        @inlinable
        public init(message: String, quotaCode: String, resourceId: String, resourceType: String, serviceCode: String) {
            self.message = message
            self.quotaCode = quotaCode
            self.resourceId = resourceId
            self.resourceType = resourceType
            self.serviceCode = serviceCode
        }

        private enum CodingKeys: String, CodingKey {
            case message = "message"
            case quotaCode = "quotaCode"
            case resourceId = "resourceId"
            case resourceType = "resourceType"
            case serviceCode = "serviceCode"
        }
    }

    public struct SingleMeasureMapping: AWSEncodableShape & AWSDecodableShape {
        /// Target measure name for the measurement attribute in the Timestream table.
        public let measureName: String
        /// Dynamic path of the source field to map to the measure in the record.
        public let measureValue: String
        /// Data type of the source field.
        public let measureValueType: MeasureValueType

        @inlinable
        public init(measureName: String, measureValue: String, measureValueType: MeasureValueType) {
            self.measureName = measureName
            self.measureValue = measureValue
            self.measureValueType = measureValueType
        }

        public func validate(name: String) throws {
            try self.validate(self.measureName, name: "measureName", parent: name, max: 1024)
            try self.validate(self.measureName, name: "measureName", parent: name, min: 1)
            try self.validate(self.measureValue, name: "measureValue", parent: name, max: 2048)
            try self.validate(self.measureValue, name: "measureValue", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case measureName = "MeasureName"
            case measureValue = "MeasureValue"
            case measureValueType = "MeasureValueType"
        }
    }

    public struct StartPipeRequest: AWSEncodableShape {
        /// The name of the pipe.
        public let name: String

        @inlinable
        public init(name: String) {
            self.name = name
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.name, key: "Name")
        }

        public func validate(name: String) throws {
            try self.validate(self.name, name: "name", parent: name, max: 64)
            try self.validate(self.name, name: "name", parent: name, min: 1)
            try self.validate(self.name, name: "name", parent: name, pattern: "^[\\.\\-_A-Za-z0-9]+$")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct StartPipeResponse: AWSDecodableShape {
        /// The ARN of the pipe.
        public let arn: String?
        /// The time the pipe was created.
        public let creationTime: Date?
        /// The state the pipe is in.
        public let currentState: PipeState?
        /// The state the pipe should be in.
        public let desiredState: RequestedPipeState?
        /// When the pipe was last updated, in ISO-8601 format (YYYY-MM-DDThh:mm:ss.sTZD).
        public let lastModifiedTime: Date?
        /// The name of the pipe.
        public let name: String?

        @inlinable
        public init(arn: String? = nil, creationTime: Date? = nil, currentState: PipeState? = nil, desiredState: RequestedPipeState? = nil, lastModifiedTime: Date? = nil, name: String? = nil) {
            self.arn = arn
            self.creationTime = creationTime
            self.currentState = currentState
            self.desiredState = desiredState
            self.lastModifiedTime = lastModifiedTime
            self.name = name
        }

        private enum CodingKeys: String, CodingKey {
            case arn = "Arn"
            case creationTime = "CreationTime"
            case currentState = "CurrentState"
            case desiredState = "DesiredState"
            case lastModifiedTime = "LastModifiedTime"
            case name = "Name"
        }
    }

    public struct StopPipeRequest: AWSEncodableShape {
        /// The name of the pipe.
        public let name: String

        @inlinable
        public init(name: String) {
            self.name = name
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.name, key: "Name")
        }

        public func validate(name: String) throws {
            try self.validate(self.name, name: "name", parent: name, max: 64)
            try self.validate(self.name, name: "name", parent: name, min: 1)
            try self.validate(self.name, name: "name", parent: name, pattern: "^[\\.\\-_A-Za-z0-9]+$")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct StopPipeResponse: AWSDecodableShape {
        /// The ARN of the pipe.
        public let arn: String?
        /// The time the pipe was created.
        public let creationTime: Date?
        /// The state the pipe is in.
        public let currentState: PipeState?
        /// The state the pipe should be in.
        public let desiredState: RequestedPipeState?
        /// When the pipe was last updated, in ISO-8601 format (YYYY-MM-DDThh:mm:ss.sTZD).
        public let lastModifiedTime: Date?
        /// The name of the pipe.
        public let name: String?

        @inlinable
        public init(arn: String? = nil, creationTime: Date? = nil, currentState: PipeState? = nil, desiredState: RequestedPipeState? = nil, lastModifiedTime: Date? = nil, name: String? = nil) {
            self.arn = arn
            self.creationTime = creationTime
            self.currentState = currentState
            self.desiredState = desiredState
            self.lastModifiedTime = lastModifiedTime
            self.name = name
        }

        private enum CodingKeys: String, CodingKey {
            case arn = "Arn"
            case creationTime = "CreationTime"
            case currentState = "CurrentState"
            case desiredState = "DesiredState"
            case lastModifiedTime = "LastModifiedTime"
            case name = "Name"
        }
    }

    public struct Tag: AWSEncodableShape & AWSDecodableShape {
        /// A string you can use to assign a value. The combination of tag keys and values can help you organize and categorize your resources.
        public let key: String
        /// The value for the specified tag key.
        public let value: String

        @inlinable
        public init(key: String, value: String) {
            self.key = key
            self.value = value
        }

        public func validate(name: String) throws {
            try self.validate(self.key, name: "key", parent: name, max: 128)
            try self.validate(self.key, name: "key", parent: name, min: 1)
            try self.validate(self.value, name: "value", parent: name, max: 256)
        }

        private enum CodingKeys: String, CodingKey {
            case key = "Key"
            case value = "Value"
        }
    }

    public struct TagResourceRequest: AWSEncodableShape {
        /// The ARN of the pipe.
        public let resourceArn: String
        /// The list of key-value pairs associated with the pipe.
        public let tags: [String: String]

        @inlinable
        public init(resourceArn: String, tags: [String: String]) {
            self.resourceArn = resourceArn
            self.tags = tags
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.resourceArn, key: "resourceArn")
            try container.encode(self.tags, forKey: .tags)
        }

        public func validate(name: String) throws {
            try self.validate(self.resourceArn, name: "resourceArn", parent: name, max: 1600)
            try self.validate(self.resourceArn, name: "resourceArn", parent: name, min: 1)
            try self.validate(self.resourceArn, name: "resourceArn", parent: name, pattern: "^arn:aws([a-z]|\\-)*:([a-zA-Z0-9\\-]+):([a-z]|\\d|\\-)*:([0-9]{12})?:(.+)$")
            try self.tags.forEach {
                try validate($0.key, name: "tags.key", parent: name, max: 128)
                try validate($0.key, name: "tags.key", parent: name, min: 1)
                try validate($0.value, name: "tags[\"\($0.key)\"]", parent: name, max: 256)
            }
            try self.validate(self.tags, name: "tags", parent: name, max: 50)
            try self.validate(self.tags, name: "tags", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case tags = "tags"
        }
    }

    public struct TagResourceResponse: AWSDecodableShape {
        public init() {}
    }

    public struct ThrottlingException: AWSErrorShape {
        public let message: String
        /// The identifier of the quota that caused the exception.
        public let quotaCode: String?
        /// The number of seconds to wait before retrying the action that caused the exception.
        public let retryAfterSeconds: Int?
        /// The identifier of the service that caused the exception.
        public let serviceCode: String?

        @inlinable
        public init(message: String, quotaCode: String? = nil, retryAfterSeconds: Int? = nil, serviceCode: String? = nil) {
            self.message = message
            self.quotaCode = quotaCode
            self.retryAfterSeconds = retryAfterSeconds
            self.serviceCode = serviceCode
        }

        public init(from decoder: Decoder) throws {
            let response = decoder.userInfo[.awsResponse]! as! ResponseDecodingContainer
            let container = try decoder.container(keyedBy: CodingKeys.self)
            self.message = try container.decode(String.self, forKey: .message)
            self.quotaCode = try container.decodeIfPresent(String.self, forKey: .quotaCode)
            self.retryAfterSeconds = try response.decodeHeaderIfPresent(Int.self, key: "Retry-After")
            self.serviceCode = try container.decodeIfPresent(String.self, forKey: .serviceCode)
        }

        private enum CodingKeys: String, CodingKey {
            case message = "message"
            case quotaCode = "quotaCode"
            case serviceCode = "serviceCode"
        }
    }

    public struct UntagResourceRequest: AWSEncodableShape {
        /// The ARN of the pipe.
        public let resourceArn: String
        /// The list of tag keys to remove from the pipe.
        public let tagKeys: [String]

        @inlinable
        public init(resourceArn: String, tagKeys: [String]) {
            self.resourceArn = resourceArn
            self.tagKeys = tagKeys
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.resourceArn, key: "resourceArn")
            request.encodeQuery(self.tagKeys, key: "tagKeys")
        }

        public func validate(name: String) throws {
            try self.validate(self.resourceArn, name: "resourceArn", parent: name, max: 1600)
            try self.validate(self.resourceArn, name: "resourceArn", parent: name, min: 1)
            try self.validate(self.resourceArn, name: "resourceArn", parent: name, pattern: "^arn:aws([a-z]|\\-)*:([a-zA-Z0-9\\-]+):([a-z]|\\d|\\-)*:([0-9]{12})?:(.+)$")
            try self.tagKeys.forEach {
                try validate($0, name: "tagKeys[]", parent: name, max: 128)
                try validate($0, name: "tagKeys[]", parent: name, min: 1)
            }
            try self.validate(self.tagKeys, name: "tagKeys", parent: name, max: 50)
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct UntagResourceResponse: AWSDecodableShape {
        public init() {}
    }

    public struct UpdatePipeRequest: AWSEncodableShape {
        /// A description of the pipe.
        public let description: String?
        /// The state the pipe should be in.
        public let desiredState: RequestedPipeState?
        /// The ARN of the enrichment resource.
        public let enrichment: String?
        /// The parameters required to set up enrichment on your pipe.
        public let enrichmentParameters: PipeEnrichmentParameters?
        /// The identifier of the KMS customer managed key for EventBridge to use, if you choose to use a customer managed key to encrypt pipe data. The identifier can be the key  Amazon Resource Name (ARN), KeyId, key alias, or key alias ARN. To update a pipe that is using the default Amazon Web Services owned key to use a customer managed key instead, or update a pipe that is using a customer managed key to use a different customer managed key, specify a customer managed key identifier. To update a pipe that is using a customer managed key to use the default Amazon Web Services owned key, specify an empty string. For more information, see Managing keys in the Key Management Service Developer Guide.
        public let kmsKeyIdentifier: String?
        /// The logging configuration settings for the pipe.
        public let logConfiguration: PipeLogConfigurationParameters?
        /// The name of the pipe.
        public let name: String
        /// The ARN of the role that allows the pipe to send data to the target.
        public let roleArn: String
        /// The parameters required to set up a source for your pipe.
        public let sourceParameters: UpdatePipeSourceParameters?
        /// The ARN of the target resource.
        public let target: String?
        /// The parameters required to set up a target for your pipe. For more information about pipe target parameters, including how to use dynamic path parameters, see Target parameters in the Amazon EventBridge User Guide.
        public let targetParameters: PipeTargetParameters?

        @inlinable
        public init(description: String? = nil, desiredState: RequestedPipeState? = nil, enrichment: String? = nil, enrichmentParameters: PipeEnrichmentParameters? = nil, kmsKeyIdentifier: String? = nil, logConfiguration: PipeLogConfigurationParameters? = nil, name: String, roleArn: String, sourceParameters: UpdatePipeSourceParameters? = nil, target: String? = nil, targetParameters: PipeTargetParameters? = nil) {
            self.description = description
            self.desiredState = desiredState
            self.enrichment = enrichment
            self.enrichmentParameters = enrichmentParameters
            self.kmsKeyIdentifier = kmsKeyIdentifier
            self.logConfiguration = logConfiguration
            self.name = name
            self.roleArn = roleArn
            self.sourceParameters = sourceParameters
            self.target = target
            self.targetParameters = targetParameters
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            try container.encodeIfPresent(self.description, forKey: .description)
            try container.encodeIfPresent(self.desiredState, forKey: .desiredState)
            try container.encodeIfPresent(self.enrichment, forKey: .enrichment)
            try container.encodeIfPresent(self.enrichmentParameters, forKey: .enrichmentParameters)
            try container.encodeIfPresent(self.kmsKeyIdentifier, forKey: .kmsKeyIdentifier)
            try container.encodeIfPresent(self.logConfiguration, forKey: .logConfiguration)
            request.encodePath(self.name, key: "Name")
            try container.encode(self.roleArn, forKey: .roleArn)
            try container.encodeIfPresent(self.sourceParameters, forKey: .sourceParameters)
            try container.encodeIfPresent(self.target, forKey: .target)
            try container.encodeIfPresent(self.targetParameters, forKey: .targetParameters)
        }

        public func validate(name: String) throws {
            try self.validate(self.description, name: "description", parent: name, max: 512)
            try self.validate(self.description, name: "description", parent: name, pattern: "^.*$")
            try self.validate(self.enrichment, name: "enrichment", parent: name, max: 1600)
            try self.validate(self.enrichment, name: "enrichment", parent: name, pattern: "^$|arn:(aws[a-zA-Z0-9-]*):([a-zA-Z0-9\\-]+):([a-z]{2,4}((-gov)|(-de)|(-iso([a-z]?)))?-[a-z]+(-\\d{1})?)?:(\\d{12})?:(.+)$")
            try self.enrichmentParameters?.validate(name: "\(name).enrichmentParameters")
            try self.validate(self.kmsKeyIdentifier, name: "kmsKeyIdentifier", parent: name, max: 2048)
            try self.validate(self.kmsKeyIdentifier, name: "kmsKeyIdentifier", parent: name, pattern: "^[a-zA-Z0-9_\\-/:]*$")
            try self.logConfiguration?.validate(name: "\(name).logConfiguration")
            try self.validate(self.name, name: "name", parent: name, max: 64)
            try self.validate(self.name, name: "name", parent: name, min: 1)
            try self.validate(self.name, name: "name", parent: name, pattern: "^[\\.\\-_A-Za-z0-9]+$")
            try self.validate(self.roleArn, name: "roleArn", parent: name, max: 1600)
            try self.validate(self.roleArn, name: "roleArn", parent: name, min: 1)
            try self.validate(self.roleArn, name: "roleArn", parent: name, pattern: "^arn:(aws[a-zA-Z-]*)?:iam::\\d{12}:role/?[a-zA-Z0-9+=,.@\\-_/]+$")
            try self.sourceParameters?.validate(name: "\(name).sourceParameters")
            try self.validate(self.target, name: "target", parent: name, max: 1600)
            try self.validate(self.target, name: "target", parent: name, min: 1)
            try self.validate(self.target, name: "target", parent: name, pattern: "^arn:(aws[a-zA-Z0-9-]*):([a-zA-Z0-9\\-]+):([a-z]{2,4}((-gov)|(-de)|(-iso([a-z]?)))?-[a-z]+(-\\d{1})?)?:(\\d{12})?:(.+)$")
            try self.targetParameters?.validate(name: "\(name).targetParameters")
        }

        private enum CodingKeys: String, CodingKey {
            case description = "Description"
            case desiredState = "DesiredState"
            case enrichment = "Enrichment"
            case enrichmentParameters = "EnrichmentParameters"
            case kmsKeyIdentifier = "KmsKeyIdentifier"
            case logConfiguration = "LogConfiguration"
            case roleArn = "RoleArn"
            case sourceParameters = "SourceParameters"
            case target = "Target"
            case targetParameters = "TargetParameters"
        }
    }

    public struct UpdatePipeResponse: AWSDecodableShape {
        /// The ARN of the pipe.
        public let arn: String?
        /// The time the pipe was created.
        public let creationTime: Date?
        /// The state the pipe is in.
        public let currentState: PipeState?
        /// The state the pipe should be in.
        public let desiredState: RequestedPipeState?
        /// When the pipe was last updated, in ISO-8601 format (YYYY-MM-DDThh:mm:ss.sTZD).
        public let lastModifiedTime: Date?
        /// The name of the pipe.
        public let name: String?

        @inlinable
        public init(arn: String? = nil, creationTime: Date? = nil, currentState: PipeState? = nil, desiredState: RequestedPipeState? = nil, lastModifiedTime: Date? = nil, name: String? = nil) {
            self.arn = arn
            self.creationTime = creationTime
            self.currentState = currentState
            self.desiredState = desiredState
            self.lastModifiedTime = lastModifiedTime
            self.name = name
        }

        private enum CodingKeys: String, CodingKey {
            case arn = "Arn"
            case creationTime = "CreationTime"
            case currentState = "CurrentState"
            case desiredState = "DesiredState"
            case lastModifiedTime = "LastModifiedTime"
            case name = "Name"
        }
    }

    public struct UpdatePipeSourceActiveMQBrokerParameters: AWSEncodableShape {
        /// The maximum number of records to include in each batch.
        public let batchSize: Int?
        /// The credentials needed to access the resource.
        public let credentials: MQBrokerAccessCredentials
        /// The maximum length of a time to wait for events.
        public let maximumBatchingWindowInSeconds: Int?

        @inlinable
        public init(batchSize: Int? = nil, credentials: MQBrokerAccessCredentials, maximumBatchingWindowInSeconds: Int? = nil) {
            self.batchSize = batchSize
            self.credentials = credentials
            self.maximumBatchingWindowInSeconds = maximumBatchingWindowInSeconds
        }

        public func validate(name: String) throws {
            try self.validate(self.batchSize, name: "batchSize", parent: name, max: 10000)
            try self.validate(self.batchSize, name: "batchSize", parent: name, min: 1)
            try self.credentials.validate(name: "\(name).credentials")
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, max: 300)
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, min: 0)
        }

        private enum CodingKeys: String, CodingKey {
            case batchSize = "BatchSize"
            case credentials = "Credentials"
            case maximumBatchingWindowInSeconds = "MaximumBatchingWindowInSeconds"
        }
    }

    public struct UpdatePipeSourceDynamoDBStreamParameters: AWSEncodableShape {
        /// The maximum number of records to include in each batch.
        public let batchSize: Int?
        /// Define the target queue to send dead-letter queue events to.
        public let deadLetterConfig: DeadLetterConfig?
        /// The maximum length of a time to wait for events.
        public let maximumBatchingWindowInSeconds: Int?
        /// Discard records older than the specified age. The default value is -1, which sets the maximum age to infinite.
        /// When the value is set to infinite, EventBridge never discards old records.
        public let maximumRecordAgeInSeconds: Int?
        /// Discard records after the specified number of retries. The default value is -1, which sets the maximum number of
        /// retries to infinite. When MaximumRetryAttempts is infinite, EventBridge retries failed records until the record expires in the event source.
        public let maximumRetryAttempts: Int?
        /// Define how to handle item process failures. AUTOMATIC_BISECT halves each batch and retry each half
        /// until all the records are processed or there is one failed message left in the batch.
        public let onPartialBatchItemFailure: OnPartialBatchItemFailureStreams?
        /// The number of batches to process concurrently from each shard. The default value is 1.
        public let parallelizationFactor: Int?

        @inlinable
        public init(batchSize: Int? = nil, deadLetterConfig: DeadLetterConfig? = nil, maximumBatchingWindowInSeconds: Int? = nil, maximumRecordAgeInSeconds: Int? = nil, maximumRetryAttempts: Int? = nil, onPartialBatchItemFailure: OnPartialBatchItemFailureStreams? = nil, parallelizationFactor: Int? = nil) {
            self.batchSize = batchSize
            self.deadLetterConfig = deadLetterConfig
            self.maximumBatchingWindowInSeconds = maximumBatchingWindowInSeconds
            self.maximumRecordAgeInSeconds = maximumRecordAgeInSeconds
            self.maximumRetryAttempts = maximumRetryAttempts
            self.onPartialBatchItemFailure = onPartialBatchItemFailure
            self.parallelizationFactor = parallelizationFactor
        }

        public func validate(name: String) throws {
            try self.validate(self.batchSize, name: "batchSize", parent: name, max: 10000)
            try self.validate(self.batchSize, name: "batchSize", parent: name, min: 1)
            try self.deadLetterConfig?.validate(name: "\(name).deadLetterConfig")
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, max: 300)
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, min: 0)
            try self.validate(self.maximumRecordAgeInSeconds, name: "maximumRecordAgeInSeconds", parent: name, max: 604800)
            try self.validate(self.maximumRecordAgeInSeconds, name: "maximumRecordAgeInSeconds", parent: name, min: -1)
            try self.validate(self.maximumRetryAttempts, name: "maximumRetryAttempts", parent: name, max: 10000)
            try self.validate(self.maximumRetryAttempts, name: "maximumRetryAttempts", parent: name, min: -1)
            try self.validate(self.parallelizationFactor, name: "parallelizationFactor", parent: name, max: 10)
            try self.validate(self.parallelizationFactor, name: "parallelizationFactor", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case batchSize = "BatchSize"
            case deadLetterConfig = "DeadLetterConfig"
            case maximumBatchingWindowInSeconds = "MaximumBatchingWindowInSeconds"
            case maximumRecordAgeInSeconds = "MaximumRecordAgeInSeconds"
            case maximumRetryAttempts = "MaximumRetryAttempts"
            case onPartialBatchItemFailure = "OnPartialBatchItemFailure"
            case parallelizationFactor = "ParallelizationFactor"
        }
    }

    public struct UpdatePipeSourceKinesisStreamParameters: AWSEncodableShape {
        /// The maximum number of records to include in each batch.
        public let batchSize: Int?
        /// Define the target queue to send dead-letter queue events to.
        public let deadLetterConfig: DeadLetterConfig?
        /// The maximum length of a time to wait for events.
        public let maximumBatchingWindowInSeconds: Int?
        /// Discard records older than the specified age. The default value is -1, which sets the maximum age to infinite.
        /// When the value is set to infinite, EventBridge never discards old records.
        public let maximumRecordAgeInSeconds: Int?
        /// Discard records after the specified number of retries. The default value is -1, which sets the maximum number of
        /// retries to infinite. When MaximumRetryAttempts is infinite, EventBridge retries failed records until the record expires in the event source.
        public let maximumRetryAttempts: Int?
        /// Define how to handle item process failures. AUTOMATIC_BISECT halves each batch and retry each half
        /// until all the records are processed or there is one failed message left in the batch.
        public let onPartialBatchItemFailure: OnPartialBatchItemFailureStreams?
        /// The number of batches to process concurrently from each shard. The default value is 1.
        public let parallelizationFactor: Int?

        @inlinable
        public init(batchSize: Int? = nil, deadLetterConfig: DeadLetterConfig? = nil, maximumBatchingWindowInSeconds: Int? = nil, maximumRecordAgeInSeconds: Int? = nil, maximumRetryAttempts: Int? = nil, onPartialBatchItemFailure: OnPartialBatchItemFailureStreams? = nil, parallelizationFactor: Int? = nil) {
            self.batchSize = batchSize
            self.deadLetterConfig = deadLetterConfig
            self.maximumBatchingWindowInSeconds = maximumBatchingWindowInSeconds
            self.maximumRecordAgeInSeconds = maximumRecordAgeInSeconds
            self.maximumRetryAttempts = maximumRetryAttempts
            self.onPartialBatchItemFailure = onPartialBatchItemFailure
            self.parallelizationFactor = parallelizationFactor
        }

        public func validate(name: String) throws {
            try self.validate(self.batchSize, name: "batchSize", parent: name, max: 10000)
            try self.validate(self.batchSize, name: "batchSize", parent: name, min: 1)
            try self.deadLetterConfig?.validate(name: "\(name).deadLetterConfig")
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, max: 300)
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, min: 0)
            try self.validate(self.maximumRecordAgeInSeconds, name: "maximumRecordAgeInSeconds", parent: name, max: 604800)
            try self.validate(self.maximumRecordAgeInSeconds, name: "maximumRecordAgeInSeconds", parent: name, min: -1)
            try self.validate(self.maximumRetryAttempts, name: "maximumRetryAttempts", parent: name, max: 10000)
            try self.validate(self.maximumRetryAttempts, name: "maximumRetryAttempts", parent: name, min: -1)
            try self.validate(self.parallelizationFactor, name: "parallelizationFactor", parent: name, max: 10)
            try self.validate(self.parallelizationFactor, name: "parallelizationFactor", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case batchSize = "BatchSize"
            case deadLetterConfig = "DeadLetterConfig"
            case maximumBatchingWindowInSeconds = "MaximumBatchingWindowInSeconds"
            case maximumRecordAgeInSeconds = "MaximumRecordAgeInSeconds"
            case maximumRetryAttempts = "MaximumRetryAttempts"
            case onPartialBatchItemFailure = "OnPartialBatchItemFailure"
            case parallelizationFactor = "ParallelizationFactor"
        }
    }

    public struct UpdatePipeSourceManagedStreamingKafkaParameters: AWSEncodableShape {
        /// The maximum number of records to include in each batch.
        public let batchSize: Int?
        /// The credentials needed to access the resource.
        public let credentials: MSKAccessCredentials?
        /// The maximum length of a time to wait for events.
        public let maximumBatchingWindowInSeconds: Int?

        @inlinable
        public init(batchSize: Int? = nil, credentials: MSKAccessCredentials? = nil, maximumBatchingWindowInSeconds: Int? = nil) {
            self.batchSize = batchSize
            self.credentials = credentials
            self.maximumBatchingWindowInSeconds = maximumBatchingWindowInSeconds
        }

        public func validate(name: String) throws {
            try self.validate(self.batchSize, name: "batchSize", parent: name, max: 10000)
            try self.validate(self.batchSize, name: "batchSize", parent: name, min: 1)
            try self.credentials?.validate(name: "\(name).credentials")
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, max: 300)
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, min: 0)
        }

        private enum CodingKeys: String, CodingKey {
            case batchSize = "BatchSize"
            case credentials = "Credentials"
            case maximumBatchingWindowInSeconds = "MaximumBatchingWindowInSeconds"
        }
    }

    public struct UpdatePipeSourceParameters: AWSEncodableShape {
        /// The parameters for using an Active MQ broker as a source.
        public let activeMQBrokerParameters: UpdatePipeSourceActiveMQBrokerParameters?
        /// The parameters for using a DynamoDB stream as a source.
        public let dynamoDBStreamParameters: UpdatePipeSourceDynamoDBStreamParameters?
        /// The collection of event patterns used to filter events. To remove a filter, specify a FilterCriteria object with an empty array of Filter objects. For more information, see Events and Event Patterns in the Amazon EventBridge User Guide.
        public let filterCriteria: FilterCriteria?
        /// The parameters for using a Kinesis stream as a source.
        public let kinesisStreamParameters: UpdatePipeSourceKinesisStreamParameters?
        /// The parameters for using an MSK stream as a source.
        public let managedStreamingKafkaParameters: UpdatePipeSourceManagedStreamingKafkaParameters?
        /// The parameters for using a Rabbit MQ broker as a source.
        public let rabbitMQBrokerParameters: UpdatePipeSourceRabbitMQBrokerParameters?
        /// The parameters for using a self-managed Apache Kafka stream as a source. A self managed cluster refers to any Apache Kafka cluster not hosted by Amazon Web Services. This includes both clusters you manage yourself, as well as those hosted by a third-party provider, such as Confluent Cloud, CloudKarafka, or Redpanda. For more information, see Apache Kafka streams as a source in the Amazon EventBridge User Guide.
        public let selfManagedKafkaParameters: UpdatePipeSourceSelfManagedKafkaParameters?
        /// The parameters for using a Amazon SQS stream as a source.
        public let sqsQueueParameters: UpdatePipeSourceSqsQueueParameters?

        @inlinable
        public init(activeMQBrokerParameters: UpdatePipeSourceActiveMQBrokerParameters? = nil, dynamoDBStreamParameters: UpdatePipeSourceDynamoDBStreamParameters? = nil, filterCriteria: FilterCriteria? = nil, kinesisStreamParameters: UpdatePipeSourceKinesisStreamParameters? = nil, managedStreamingKafkaParameters: UpdatePipeSourceManagedStreamingKafkaParameters? = nil, rabbitMQBrokerParameters: UpdatePipeSourceRabbitMQBrokerParameters? = nil, selfManagedKafkaParameters: UpdatePipeSourceSelfManagedKafkaParameters? = nil, sqsQueueParameters: UpdatePipeSourceSqsQueueParameters? = nil) {
            self.activeMQBrokerParameters = activeMQBrokerParameters
            self.dynamoDBStreamParameters = dynamoDBStreamParameters
            self.filterCriteria = filterCriteria
            self.kinesisStreamParameters = kinesisStreamParameters
            self.managedStreamingKafkaParameters = managedStreamingKafkaParameters
            self.rabbitMQBrokerParameters = rabbitMQBrokerParameters
            self.selfManagedKafkaParameters = selfManagedKafkaParameters
            self.sqsQueueParameters = sqsQueueParameters
        }

        public func validate(name: String) throws {
            try self.activeMQBrokerParameters?.validate(name: "\(name).activeMQBrokerParameters")
            try self.dynamoDBStreamParameters?.validate(name: "\(name).dynamoDBStreamParameters")
            try self.filterCriteria?.validate(name: "\(name).filterCriteria")
            try self.kinesisStreamParameters?.validate(name: "\(name).kinesisStreamParameters")
            try self.managedStreamingKafkaParameters?.validate(name: "\(name).managedStreamingKafkaParameters")
            try self.rabbitMQBrokerParameters?.validate(name: "\(name).rabbitMQBrokerParameters")
            try self.selfManagedKafkaParameters?.validate(name: "\(name).selfManagedKafkaParameters")
            try self.sqsQueueParameters?.validate(name: "\(name).sqsQueueParameters")
        }

        private enum CodingKeys: String, CodingKey {
            case activeMQBrokerParameters = "ActiveMQBrokerParameters"
            case dynamoDBStreamParameters = "DynamoDBStreamParameters"
            case filterCriteria = "FilterCriteria"
            case kinesisStreamParameters = "KinesisStreamParameters"
            case managedStreamingKafkaParameters = "ManagedStreamingKafkaParameters"
            case rabbitMQBrokerParameters = "RabbitMQBrokerParameters"
            case selfManagedKafkaParameters = "SelfManagedKafkaParameters"
            case sqsQueueParameters = "SqsQueueParameters"
        }
    }

    public struct UpdatePipeSourceRabbitMQBrokerParameters: AWSEncodableShape {
        /// The maximum number of records to include in each batch.
        public let batchSize: Int?
        /// The credentials needed to access the resource.
        public let credentials: MQBrokerAccessCredentials
        /// The maximum length of a time to wait for events.
        public let maximumBatchingWindowInSeconds: Int?

        @inlinable
        public init(batchSize: Int? = nil, credentials: MQBrokerAccessCredentials, maximumBatchingWindowInSeconds: Int? = nil) {
            self.batchSize = batchSize
            self.credentials = credentials
            self.maximumBatchingWindowInSeconds = maximumBatchingWindowInSeconds
        }

        public func validate(name: String) throws {
            try self.validate(self.batchSize, name: "batchSize", parent: name, max: 10000)
            try self.validate(self.batchSize, name: "batchSize", parent: name, min: 1)
            try self.credentials.validate(name: "\(name).credentials")
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, max: 300)
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, min: 0)
        }

        private enum CodingKeys: String, CodingKey {
            case batchSize = "BatchSize"
            case credentials = "Credentials"
            case maximumBatchingWindowInSeconds = "MaximumBatchingWindowInSeconds"
        }
    }

    public struct UpdatePipeSourceSelfManagedKafkaParameters: AWSEncodableShape {
        /// The maximum number of records to include in each batch.
        public let batchSize: Int?
        /// The credentials needed to access the resource.
        public let credentials: SelfManagedKafkaAccessConfigurationCredentials?
        /// The maximum length of a time to wait for events.
        public let maximumBatchingWindowInSeconds: Int?
        /// The ARN of the Secrets Manager secret used for certification.
        public let serverRootCaCertificate: String?
        /// This structure specifies the VPC subnets and security groups for the stream, and whether a public IP address is to be used.
        public let vpc: SelfManagedKafkaAccessConfigurationVpc?

        @inlinable
        public init(batchSize: Int? = nil, credentials: SelfManagedKafkaAccessConfigurationCredentials? = nil, maximumBatchingWindowInSeconds: Int? = nil, serverRootCaCertificate: String? = nil, vpc: SelfManagedKafkaAccessConfigurationVpc? = nil) {
            self.batchSize = batchSize
            self.credentials = credentials
            self.maximumBatchingWindowInSeconds = maximumBatchingWindowInSeconds
            self.serverRootCaCertificate = serverRootCaCertificate
            self.vpc = vpc
        }

        public func validate(name: String) throws {
            try self.validate(self.batchSize, name: "batchSize", parent: name, max: 10000)
            try self.validate(self.batchSize, name: "batchSize", parent: name, min: 1)
            try self.credentials?.validate(name: "\(name).credentials")
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, max: 300)
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, min: 0)
            try self.validate(self.serverRootCaCertificate, name: "serverRootCaCertificate", parent: name, max: 1600)
            try self.validate(self.serverRootCaCertificate, name: "serverRootCaCertificate", parent: name, min: 1)
            try self.validate(self.serverRootCaCertificate, name: "serverRootCaCertificate", parent: name, pattern: "^(^arn:aws([a-z]|\\-)*:secretsmanager:([a-z]{2,4}((-gov)|(-de)|(-iso([a-z]?)))?-[a-z]+(-\\d{1})?):(\\d{12}):secret:.+)$")
            try self.vpc?.validate(name: "\(name).vpc")
        }

        private enum CodingKeys: String, CodingKey {
            case batchSize = "BatchSize"
            case credentials = "Credentials"
            case maximumBatchingWindowInSeconds = "MaximumBatchingWindowInSeconds"
            case serverRootCaCertificate = "ServerRootCaCertificate"
            case vpc = "Vpc"
        }
    }

    public struct UpdatePipeSourceSqsQueueParameters: AWSEncodableShape {
        /// The maximum number of records to include in each batch.
        public let batchSize: Int?
        /// The maximum length of a time to wait for events.
        public let maximumBatchingWindowInSeconds: Int?

        @inlinable
        public init(batchSize: Int? = nil, maximumBatchingWindowInSeconds: Int? = nil) {
            self.batchSize = batchSize
            self.maximumBatchingWindowInSeconds = maximumBatchingWindowInSeconds
        }

        public func validate(name: String) throws {
            try self.validate(self.batchSize, name: "batchSize", parent: name, max: 10000)
            try self.validate(self.batchSize, name: "batchSize", parent: name, min: 1)
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, max: 300)
            try self.validate(self.maximumBatchingWindowInSeconds, name: "maximumBatchingWindowInSeconds", parent: name, min: 0)
        }

        private enum CodingKeys: String, CodingKey {
            case batchSize = "BatchSize"
            case maximumBatchingWindowInSeconds = "MaximumBatchingWindowInSeconds"
        }
    }

    public struct ValidationException: AWSErrorShape {
        /// The list of fields for which validation failed and the corresponding failure messages.
        public let fieldList: [ValidationExceptionField]?
        public let message: String?

        @inlinable
        public init(fieldList: [ValidationExceptionField]? = nil, message: String? = nil) {
            self.fieldList = fieldList
            self.message = message
        }

        private enum CodingKeys: String, CodingKey {
            case fieldList = "fieldList"
            case message = "message"
        }
    }

    public struct ValidationExceptionField: AWSDecodableShape {
        /// The message of the exception.
        public let message: String
        /// The name of the exception.
        public let name: String

        @inlinable
        public init(message: String, name: String) {
            self.message = message
            self.name = name
        }

        private enum CodingKeys: String, CodingKey {
            case message = "message"
            case name = "name"
        }
    }

    public struct MQBrokerAccessCredentials: AWSEncodableShape & AWSDecodableShape {
        /// The ARN of the Secrets Manager secret.
        public let basicAuth: String?

        @inlinable
        public init(basicAuth: String? = nil) {
            self.basicAuth = basicAuth
        }

        public func validate(name: String) throws {
            try self.validate(self.basicAuth, name: "basicAuth", parent: name, max: 1600)
            try self.validate(self.basicAuth, name: "basicAuth", parent: name, min: 1)
            try self.validate(self.basicAuth, name: "basicAuth", parent: name, pattern: "^(^arn:aws([a-z]|\\-)*:secretsmanager:([a-z]{2,4}((-gov)|(-de)|(-iso([a-z]?)))?-[a-z]+(-\\d{1})?):(\\d{12}):secret:.+)$")
        }

        private enum CodingKeys: String, CodingKey {
            case basicAuth = "BasicAuth"
        }
    }
}

// MARK: - Errors

/// Error enum for Pipes
public struct PipesErrorType: AWSErrorType {
    enum Code: String {
        case conflictException = "ConflictException"
        case internalException = "InternalException"
        case notFoundException = "NotFoundException"
        case serviceQuotaExceededException = "ServiceQuotaExceededException"
        case throttlingException = "ThrottlingException"
        case validationException = "ValidationException"
    }

    private let error: Code
    public let context: AWSErrorContext?

    /// initialize Pipes
    public init?(errorCode: String, context: AWSErrorContext) {
        guard let error = Code(rawValue: errorCode) else { return nil }
        self.error = error
        self.context = context
    }

    internal init(_ error: Code) {
        self.error = error
        self.context = nil
    }

    /// return error code string
    public var errorCode: String { self.error.rawValue }

    /// An action you attempted resulted in an exception.
    public static var conflictException: Self { .init(.conflictException) }
    /// This exception occurs due to unexpected causes.
    public static var internalException: Self { .init(.internalException) }
    /// An entity that you specified does not exist.
    public static var notFoundException: Self { .init(.notFoundException) }
    /// A quota has been exceeded.
    public static var serviceQuotaExceededException: Self { .init(.serviceQuotaExceededException) }
    /// An action was throttled.
    public static var throttlingException: Self { .init(.throttlingException) }
    /// Indicates that an error has occurred while performing a validate operation.
    public static var validationException: Self { .init(.validationException) }
}

extension PipesErrorType: AWSServiceErrorType {
    public static let errorCodeMap: [String: AWSErrorShape.Type] = [
        "ConflictException": Pipes.ConflictException.self,
        "InternalException": Pipes.InternalException.self,
        "ServiceQuotaExceededException": Pipes.ServiceQuotaExceededException.self,
        "ThrottlingException": Pipes.ThrottlingException.self,
        "ValidationException": Pipes.ValidationException.self
    ]
}

extension PipesErrorType: Equatable {
    public static func == (lhs: PipesErrorType, rhs: PipesErrorType) -> Bool {
        lhs.error == rhs.error
    }
}

extension PipesErrorType: CustomStringConvertible {
    public var description: String {
        return "\(self.error.rawValue): \(self.message ?? "")"
    }
}
